How can I make a development copy of my site in a subdirectory to test out a theme?

You can create a development copy of the existing site by:

  1. Copying all the existing files to the subdirectory.
  2. Making a copy of the database and pointing to the database copy in the /new/wp-config.php file. You will need to change the options homeurl and siteurl in new database’s wp_options table to add /new/ to the end of it.
  3. Login to the test site and install the theme and activate the theme to test it.

Alternatively there are staging plugins available that can do most or all of this process for you such as Duplicator and Sandbox.

Another possibility is to install the new theme on the existing site and test it with a tool such as Theme Test Drive plugin or Toolbar Theme Switcher. Usually you can configure the theme while testing it this way, but not always – it depends on how the theme saves it’s settings.