# How to open site created with previous version of Local?

**URL:** <https://community.localwp.com/t/how-to-open-site-created-with-previous-version-of-local/39087>\
**Category:** Support\
**Tags:** site-import, mac, local-versions\
**Created:** [September 14, 2023, 6:05pm UTC](https://community.localwp.com/t/how-to-open-site-created-with-previous-version-of-local/39087 "2023-09-14T18:05:54Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![radionowhere](https://sea1.discourse-cdn.com/flex019/user_avatar/community.localwp.com/radionowhere/32/19519_2.png) [@radionowhere](https://community.localwp.com/u/radionowhere)\
**Post date:** [September 14, 2023, 6:05pm UTC](https://community.localwp.com/t/how-to-open-site-created-with-previous-version-of-local/39087/1 "2023-09-14T18:05:54Z")

</div>

I’m trying to reopen an old site created with Local in 2019. According to local.site.json, it was version 2.2.4.

When I drag the site’s root folder to Local, I get an error message that reads “Sorry! We couldn’t figure out what to do with the import file provided. Please extract it manually.”

When I use my Mac’s native compression utility to zip the file and then drop the zip archive into Local, I get an error message that says “Please try again with a compatible Zip file”.

Solutions?

* * *

### What steps can be taken to replicate the issue? Feel free to include screenshots, videos, etc

* * *

### System Details

Local Version 7.1.2+6410

## MacOS 12.6.2

### Local Logs

Attach your Local Logs here ([Help Doc - Retrieving Local’s Log](https://localwp.com/help-docs/troubleshooting/retrieving-locals-log-file/))  
[local-logs.zip](https://community.localwp.com/uploads/short-url/x0eQSYI5EFm1WccRpFPaMmknPVj.zip) (21.4 KB)

* * *

_ **Security Reminder** _  
Local does a pretty good job of scrubbing private info from the logs and the errors it produces, however there’s always the possibility that something private can come through. Because these are public forums, always review the screenshots you are sharing to make sure there isn’t private info like passwords being displayed.

---

<div class="post-metadata">

**Author:** ![Nick-B](https://sea1.discourse-cdn.com/flex019/user_avatar/community.localwp.com/nick-b/32/16140_2.png) [@Nick-B](https://community.localwp.com/u/Nick-B)\
**Post date:** [September 14, 2023, 7:13pm UTC](https://community.localwp.com/t/how-to-open-site-created-with-previous-version-of-local/39087/2 "2023-09-14T19:13:57Z")

</div>

Hi @radionowhere!

You could attempt a more manual import. The steps would look like this:

- Unzip the file in a common location, like the desktop
- Create a new, blank site in Local. Use whatever username/password you like since you’ll overwrite the DB with this site archive’s dump.
- Copy the wp-content folder from the unzipped location to this newly created site’s location
- Copy the correct SQL dump to the site root.
- Within Local, open the site shell
- Import the dump with `wp db import <dumpfile>`
- If that works, now Search and replace the domains. `wp search-replace ' https://production.com ' 'http:mylocalsite.local'`

---

<div class="post-metadata">

**Author:** ![radionowhere](https://sea1.discourse-cdn.com/flex019/user_avatar/community.localwp.com/radionowhere/32/19519_2.png) [@radionowhere](https://community.localwp.com/u/radionowhere)\
**Post date:** [September 14, 2023, 9:28pm UTC](https://community.localwp.com/t/how-to-open-site-created-with-previous-version-of-local/39087/3 "2023-09-14T21:28:25Z")

</div>

Thx, Nick-B! A few questions:

- can you tell me what the correct SQL dump is? There are 34 SQL files in the source site’s “sql” folder (as shown in the attached screenshot)
- once I’ve got that file, what’s the correct syntax/filepath for importing in Terminal?  
 ![Screen Shot 2023-09-14 at 2.27.50 PM](https://us1.discourse-cdn.com/flex019/uploads/lwpforums/original/3X/c/7/c79b12c532af0cb5d639d02c482a30261d59abc7.png)

---

<div class="post-metadata">

**Author:** ![Nick-B](https://sea1.discourse-cdn.com/flex019/user_avatar/community.localwp.com/nick-b/32/16140_2.png) [@Nick-B](https://community.localwp.com/u/Nick-B)\
**Post date:** [September 15, 2023, 1:39pm UTC](https://community.localwp.com/t/how-to-open-site-created-with-previous-version-of-local/39087/4 "2023-09-15T13:39:17Z")

</div>

You could just be using the whole SQL file under the `app` directory. Everything in the SQL file are your individual DB tables and what not.

---

<div class="post-metadata">

**Author:** ![radionowhere](https://sea1.discourse-cdn.com/flex019/user_avatar/community.localwp.com/radionowhere/32/19519_2.png) [@radionowhere](https://community.localwp.com/u/radionowhere)\
**Post date:** [September 15, 2023, 6:10pm UTC](https://community.localwp.com/t/how-to-open-site-created-with-previous-version-of-local/39087/5 "2023-09-15T18:10:06Z")

</div>

> [@Nick-B](#):
>
> Import the dump with `wp db import <dumpfile>`

Great, thx!

Can you tell me how to " \* Import the dump with `wp db import <dumpfile>`"?

---

<div class="post-metadata">

**Author:** ![Nick-B](https://sea1.discourse-cdn.com/flex019/user_avatar/community.localwp.com/nick-b/32/16140_2.png) [@Nick-B](https://community.localwp.com/u/Nick-B)\
**Post date:** [September 15, 2023, 6:11pm UTC](https://community.localwp.com/t/how-to-open-site-created-with-previous-version-of-local/39087/6 "2023-09-15T18:11:35Z")

</div>

Once the SQL file is your site root, you can click on the `Open Site Shell` button in your Local app to spin up a terminal box. That’s where you’ll run the import command!

---

<div class="post-metadata">

**Author:** ![radionowhere](https://sea1.discourse-cdn.com/flex019/user_avatar/community.localwp.com/radionowhere/32/19519_2.png) [@radionowhere](https://community.localwp.com/u/radionowhere)\
**Post date:** [September 15, 2023, 6:38pm UTC](https://community.localwp.com/t/how-to-open-site-created-with-previous-version-of-local/39087/7 "2023-09-15T18:38:53Z")

</div>

Thx. But what’s the syntax of the import command? When I drop “wp db import ” into Terminal, I get “bash: syntax error near unexpected token `newline’”, I assume because in place of “dumpfile” I need an actual filepath?

---

<div class="post-metadata">

**Author:** ![Nick-B](https://sea1.discourse-cdn.com/flex019/user_avatar/community.localwp.com/nick-b/32/16140_2.png) [@Nick-B](https://community.localwp.com/u/Nick-B)\
**Post date:** [September 15, 2023, 6:44pm UTC](https://community.localwp.com/t/how-to-open-site-created-with-previous-version-of-local/39087/8 "2023-09-15T18:44:36Z")

</div>

Correct! To be more accurate your command would look like `wp db import filename`. Sorry if that was confusing!

---

<div class="post-metadata">

**Author:** ![radionowhere](https://sea1.discourse-cdn.com/flex019/user_avatar/community.localwp.com/radionowhere/32/19519_2.png) [@radionowhere](https://community.localwp.com/u/radionowhere)\
**Post date:** [September 15, 2023, 6:57pm UTC](https://community.localwp.com/t/how-to-open-site-created-with-previous-version-of-local/39087/9 "2023-09-15T18:57:07Z")

</div>

But am i trying to import all 35 sql files? Sorry to be so confused! Could you tell me, based on the screenshot above, what my version of “wp db import filename” should look like?

---

<div class="post-metadata">

**Author:** ![Nick-B](https://sea1.discourse-cdn.com/flex019/user_avatar/community.localwp.com/nick-b/32/16140_2.png) [@Nick-B](https://community.localwp.com/u/Nick-B)\
**Post date:** [September 15, 2023, 8:03pm UTC](https://community.localwp.com/t/how-to-open-site-created-with-previous-version-of-local/39087/10 "2023-09-15T20:03:05Z")

</div>

Apologies for the confusion! I’m not sure why the DB is broken down like that but it predates my experience with Local. I think we will need to change gears here and do something different. What you’ll need to do is `Start` your site, go to the Database tab, and then `Open Adminer`. Once in there you can click on `Import` on the left-hand side and import each of those SQL files. It will be 1 at a time, but that might be the easiest way to get this updated. The good news is once you have it done this way you shouldn’t ever have to do it again!

---

<div class="post-metadata">

**Author:** ![system](https://sea1.discourse-cdn.com/flex019/user_avatar/community.localwp.com/system/32/1_2.png) [@system](https://community.localwp.com/u/system)\
**Post date:** [December 14, 2023, 8:03pm UTC](https://community.localwp.com/t/how-to-open-site-created-with-previous-version-of-local/39087/11 "2023-12-14T20:03:49Z")

</div>

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
