Title: WordPress URL Setting
Last modified: August 19, 2016

---

# WordPress URL Setting

 *  Resolved [Shaun](https://wordpress.org/support/users/cyraxeon/)
 * (@cyraxeon)
 * [15 years, 5 months ago](https://wordpress.org/support/topic/wordpress-url-setting/)
 * I use wordpress a lot for work and we always tend to build the site/theme/etc
   on a dev server and move it to the production server upon completion.
 * Having the wp blog url stored in the db leaves most of the site links broken 
   until it is updated once the site is moved over. While not incapacitating it 
   is slightly annoying. Recently I had to deal with trying to set up WP on a SSL
   host (which didnt go well at all), but the url seemed to never work (could have
   been a server setting redirecting).
 * What I would propose is storing this variable in the wp-config.php file instead,
   it seems like it would be easier to update here even if you could not log into
   the wp-admin (yes I know you can manually do it via the db).

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Moderator [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [15 years, 5 months ago](https://wordpress.org/support/topic/wordpress-url-setting/#post-1839898)
 * You can.
 *     ```
       define('WP_SITEURL', 'http://example.com/wordpress');
       define('WP_HOME', 'http://example.com/wordpress');
       ```
   
 * Most of the time, though, you build the site out on it’s own URL and then use
   the tricks in moving WordPress to solve that problem. Not like WP will run without
   the DB anyway 😉
 *  Thread Starter [Shaun](https://wordpress.org/support/users/cyraxeon/)
 * (@cyraxeon)
 * [15 years, 5 months ago](https://wordpress.org/support/topic/wordpress-url-setting/#post-1839907)
 * when WP pulls those values from the db is is just using the php define function
   to set them anyway?
 * If thats the case I will always add those lines to my wp-config, however, when
   wordpress sets them from the db is it going to give errors? because im assuming
   it isnt using
 * > [@define](https://wordpress.org/support/users/define/)(‘WP_SITEURL’, ‘[http://example.com/wordpress&#8217](http://example.com/wordpress&#8217););
 * note the “@”
 *  Moderator [Ipstenu (Mika Epstein)](https://wordpress.org/support/users/ipstenu/)
 * (@ipstenu)
 * 🏳️‍🌈 Advisor and Activist
 * [15 years, 5 months ago](https://wordpress.org/support/topic/wordpress-url-setting/#post-1839941)
 * No, the config file overrides the database. You should be fine, and I’ve never
   needed to preface it with the @ symbol.
 *  Thread Starter [Shaun](https://wordpress.org/support/users/cyraxeon/)
 * (@cyraxeon)
 * [15 years, 5 months ago](https://wordpress.org/support/topic/wordpress-url-setting/#post-1839947)
 * wow thats awesome!! thank you!! just set it up

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘WordPress URL Setting’ is closed to new replies.

## Tags

 * [blog url](https://wordpress.org/support/topic-tag/blog-url/)
 * [site url](https://wordpress.org/support/topic-tag/site-url/)
 * [wordpress-url](https://wordpress.org/support/topic-tag/wordpress-url/)

 * In: [Requests and Feedback](https://wordpress.org/support/forum/requests-and-feedback/)
 * 4 replies
 * 2 participants
 * Last reply from: [Shaun](https://wordpress.org/support/users/cyraxeon/)
 * Last activity: [15 years, 5 months ago](https://wordpress.org/support/topic/wordpress-url-setting/#post-1839947)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
