Error Restoring Azure BACPAC to Local SQL


When I try to restore a BACPAC created by Sql Backup and FTP I get a “File contains corrupted data” error.

I’m using SqlPackage.EXE to restore the BACPAC to a local SQL Server. If I use SqlPackage to create the BACPAC, the restore works.

Big Picture: we have an Azure SQL database that is used for a live website. We backup the database to a local server using Sql Backup and FTP every night. We want the ability to restore the BACPAC file to a local SQL Server for website development and testing purposes.



Sorry, but there is no way to use SQLBackupAndFTP to backup your Azure SQL databases and restore them to your SQL Server. We can suggest you the following workaround:

SqlPackage.exe is a command-line utility, it means that you can use “Run custom scripts” option at SQLBackupAndFTP and add a script that will be performed after the backup.

For easier searching your last backup you can use “Customize backup file name” option at the “Compression Settings” window.


Just to clarify, are you saying that the BACPAC created SQL Backup and FTP is “unique” and can’t be restored using normal SQL Server?

I know that I can just use SqlPackage.EXE to backup my Azure SQL database. I chose to purchase SBAF (SQL Backup and FTP) because it made the whole process easier. But if the BACPAC that SBAF creates can’t be restored, then I will have no choice other than return the program and just use SqlPackage.


SQLBackupAndFTP creates BACPAC file in the same way (standard) as you do it with Azure. SQLBackupAndFTP can restore such backups automatically to your Azure SQL databases but if you need to restore BACPAC files to your Local SQL Server please use the workaround described above. Just add the script to your backup job to restore your BACPAC files to your Local SQL Server databases automatically.

Sorry for the inconvenience.


I think we were having a miscommunication. I wasn’t trying to use SBAF (SQL Backup and FTP) to do the actual restoring of the BACPAC file to a local SQL Server. The issue is that BACPAC file could not be restored.

In my testing I could see that SBAF created a BACPAC file, but I was having difficulty restoring it. I always like to test my backups by making sure that I can restore them.

I thought the issue might be that SBAF created special BACPAC files that could only be restored using SBAF and not with other tools like SqlPackage.EXE.

Today I tried restoring a different BACPAC file (created by SBAF) and the restore worked. So I think the issue was just a bad backup. Thank you for replies.



Good news! Thank you for the feedback.

Please feel free to contact us on any issues or concerns.


I have tried to restore a .bacpac file to Azure SQL Database - but I cannot make it work.

Application returns this error:
ERROR: Failed to restore Demo Database NAV (11-0) database. Restore azure is not supported.

Have I done something wrong or isn’t it supported anymore?



Hi Jeol,

Thanks for the details, we have fixed this issue, could you please install the following release and check it

Please let us know if it works.

Sorry for the inconvenience.



I can confirm that I can restore a .bacpac database to Azure SQL Database now!



Hi Jeol,

Good news, thanks for the feedback! Please feel free to contact us on any issues or concerns.