Drupal clean URLs fail after moving hosts because the new server is not routing requests to Drupal. Clean URLs are readable paths like `/contact` instead of `/?q=contact`, and they need server help to work. Check web server routing by confirming rewrite support, the site document root, and that Drupal receives requests for non-file paths. Most failures come from a missing setting on the new host, not broken content.
Table of Contents
- Why does a move break clean URLs?
- Is Drupal or the server causing the failure?
- How do you check routing on Apache?
- How do you check routing on Nginx?
- What should you fix before finishing?
- Frequently Asked Questions
Why does a move break clean URLs?
A host move changes the software in front of Drupal. Apache, Nginx, file paths, and default settings often differ between old and new plans. A rule that worked before may be ignored, missing, or pointed at the wrong folder.
Database content and modules usually transfer correctly. If the front page loads but inner pages return 404, routing is the likely cause. If nothing loads, check DNS, document root, database credentials, and file permissions first.
Is Drupal or the server causing the failure?
Test with the non-clean form of an inner URL. Visit a page as `/?q=about` or `/index.php?q=about`, using a real path from your site. If that page loads while `/about` returns 404, Drupal is working and the server is not forwarding clean paths.
Check whether the front page loads and whether admin pages behave the same way. A site-wide 500 error points more toward file permissions, PHP version, or a bad directive in `.htaccess`. A clean-URL-only 404 points toward rewrites or location blocks.
How do you check routing on Apache?
Confirm Drupal's `.htaccess` file moved with the site and sits in the public root. Some migration tools skip hidden files, so compare file counts or re-upload `.htaccess` from a fresh copy of your Drupal version.
Then confirm the site's document root points to the folder containing `index.php`. Shared hosts may restrict override settings. If clean URLs cannot be enabled, ask support whether directory overrides are allowed for your plan.
- Confirm `mod_rewrite` is enabled on the new host.
- Confirm the virtual host allows overrides for the Drupal folder.
- Visit Configuration > Search and metadata > Clean URLs and run the built-in test.
- Check server error logs after loading one failing clean URL.
How do you check routing on Nginx?
Nginx does not use `.htaccess`, so Apache rewrite rules do nothing after a move to Nginx. Routing depends on the server block, which often needs a manual change during migration. Look for a `location /` rule that tries files first, then passes the request to `/index.php`.
Also check that the root directive points to Drupal's public files and that PHP requests reach the correct processor. Common issues include a stale root path, a missing Drupal-specific include, or separate HTTP and HTTPS server blocks where only one was updated. After any change, reload the server configuration and retest an inner page.
What should you fix before finishing?
Re-save clean-URL settings after routing is corrected. Clear Drupal caches so old links, redirects, and menu paths rebuild. Test several content types, views, login, search, forms, and files with private downloads.
Watch for mixed results caused by caching, CDN rules, or hard-coded redirects. Update trusted host settings, base URL settings, redirect rules, and scheduled tasks if paths or domains changed. Keep a note of the working rewrite or location-block change for the next move.
Frequently Asked Questions
Will re-saving aliases fix clean URLs after a move?
No. Aliases change the path text, but the server must still send that path to Drupal.
Should you edit core rewrite files as a quick fix?
No. Fix the server configuration and keep Drupal's default routing file intact so updates remain safe.




