Hupspot Guide: Clean WordPress URLs
If you admire how Hubspot keeps URLs clean and professional, you can do the same in WordPress by removing /wordpress from your site address without breaking anything.
This guide follows a clear, Hubspot-inspired structure to show you exactly how to move a WordPress installation from a subdirectory such as /wordpress to your root domain, so visitors see https://example.com instead of https://example.com/wordpress.
What This Hubspot-Style Tutorial Covers
Many site owners install WordPress into a subfolder called /wordpress for testing or convenience, then later want a simpler URL. This Hubspot-like walkthrough will explain how to:
- Understand why
/wordpressappears in your URL - Prepare safe backups before any URL change
- Update WordPress Address and Site Address correctly
- Move or copy core files from
/wordpressto the root directory - Fix broken links, images, and redirects after the move
The process is based on the steps outlined in the original article from HubSpot at this source page, adapted into a consolidated how-to guide.
How WordPress Ends Up With “/wordpress” in the URL
In many one-click installs, the hosting provider places WordPress in a subdirectory. For example:
- Root directory:
/public_html/or/www/ - WordPress directory:
/public_html/wordpress/
When WordPress lives in that folder, the public site URL becomes https://example.com/wordpress. To mirror the clean domain style you see on major sites and in Hubspot examples, you need to serve the site from the root directory.
Before You Start: Hubspot-Level Preparation
A Hubspot-quality migration always starts with preparation. Changing URL paths can break a site if you skip backups or overlook configuration details.
1. Back Up Your Site Files
Create a full backup of your WordPress files, including:
wp-content(themes, plugins, uploads)wp-adminandwp-includes- All root files like
wp-config.php,.htaccess, andindex.php
You can back up via your hosting file manager, FTP/SFTP, or a backup plugin.
2. Back Up the Database
Use phpMyAdmin or your hosting control panel to export the database:
- Open phpMyAdmin.
- Select your WordPress database.
- Click Export and download the SQL file.
This mirrors the risk management approach you’ll often see recommended in Hubspot technical guides.
Method 1: Change URLs in WordPress Settings (Simple)
If your hosting setup already supports serving files from the root, you may only need to adjust two fields in the dashboard.
Step-by-Step Hubspot-Style Process
-
Log in to your WordPress dashboard.
-
Go to Settings > General.
-
Locate these fields:
- WordPress Address (URL)
- Site Address (URL)
-
They will currently look like:
https://example.com/wordpress
-
Change both to the clean domain:
https://example.com
-
Scroll down and click Save Changes.
After doing this, log out and log back in using the new URL. If the home page loads correctly and you can access the dashboard, your site is now using the cleaner address.
Method 2: Move WordPress From “/wordpress” to Root
If the core files really sit in a /wordpress folder and the root is empty or hosting static files, you will likely need to move those files. The original Hubspot article outlines this more technical route, which we’ll translate into clear actions below.
1. Access Your Site Files
Use one of these tools:
- cPanel File Manager
- FTP/SFTP client (FileZilla, Cyberduck, etc.)
- Hosting provider’s file explorer
Navigate to your main public directory, usually /public_html/ or /www/.
2. Locate the “/wordpress” Folder
Inside /public_html/, you should see a folder named wordpress. Open it and confirm it contains core WordPress files, for example:
wp-config.phpwp-contentwp-adminwp-includes
3. Move Files to the Root Directory
Now move the contents of the /wordpress directory into the root directory, not the folder itself.
- Select all files and folders inside
/wordpress. - Use Move or drag-and-drop to transfer them into
/public_html/. - Ensure that root now contains the WordPress core files directly.
This is the critical step that actually removes the dependency on the /wordpress subdirectory.
4. Update URL Settings After the Move
Once the files are in the root:
- Visit
https://example.com/wp-admin. - Log in and go to Settings > General.
- Confirm both URL fields read
https://example.comwithout/wordpress.
If you cannot access the dashboard, you can also update these values directly in the database using phpMyAdmin by editing the siteurl and home rows in the wp_options table.
Cleaning Up: Redirects and Broken Links
A thorough clean-up is part of any Hubspot-grade optimization, ensuring users and search engines both land on the right pages.
Set 301 Redirects
To preserve SEO value, redirect old URLs that include /wordpress to their new versions:
- Open your
.htaccessfile in the root directory. - Add redirect rules similar to:
RedirectMatch 301 ^/wordpress/(.*)$ https://example.com/$1
This tells browsers and search engines that the old paths have permanently moved.
Update Internal Links and Media
Some content may still reference /wordpress in:
- Internal page links
- Image URLs
- Menu items and widgets
Use a search-and-replace plugin or a database search to change https://example.com/wordpress to https://example.com in your content and options.
Testing Your New URL Structure
With the technical changes done, test thoroughly:
- Load the home page and several inner pages.
- Check the WordPress dashboard and settings pages.
- Test blog posts, category archives, and search.
- Open media files to confirm images are not broken.
This careful verification echoes the quality-assurance mindset you’ll see in Hubspot documentation.
Additional Hubspot-Inspired Best Practices
To keep your site running smoothly after the change:
- Update your sitemap and resubmit it in Google Search Console.
- Check your analytics settings to ensure tracking still works under the new URL.
- Monitor 404 reports and fix any missed redirects.
If you need broader strategic help with SEO, redirects, and analytics after the move, you can explore professional consulting at Consultevo, which offers guidance similar in depth and clarity to what you might expect from a Hubspot partner-style resource.
Where to Learn More
This tutorial is based on the approach detailed by HubSpot in their own documentation, specifically the article on how to remove /wordpress from a site URL. For additional screenshots, examples, and context, you can review the full guide on the original HubSpot resource.
By following these structured steps, you can move your WordPress installation out of the /wordpress folder, achieve clean URLs like the ones you see on Hubspot, and protect both user experience and search visibility.
Need Help With Hubspot?
If you want expert help building, automating, or scaling your Hubspot , work with ConsultEvo, a team who has a decade of Hubspot experience.
“`
