<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/bacpac-and-dacpac-the-similarities-and-differences-gqomyrq66" -->

---
title: Bacpac and Dacpac, the similarities and differences
description: Bacpac and dacpac files both serve database portability but differ in scope: a bacpac is a portable schema-plus-data copy limited to objects compatible with...
canonical: https://daily.dev/posts/bacpac-and-dacpac-the-similarities-and-differences-gqomyrq66
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Bacpac and Dacpac, the similarities and differences | daily.dev
og:description: Bacpac and dacpac files both serve database portability but differ in scope: a bacpac is a portable schema-plus-data copy limited to objects compatible with...
og:url: https://daily.dev/posts/bacpac-and-dacpac-the-similarities-and-differences-gqomyrq66
og:image: https://api.daily.dev/og/posts/gQoMyRQ66.png
og:image:alt: Bacpac and Dacpac, the similarities and differences
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Bacpac and Dacpac, the similarities and differences

**[DevBlogs](https://daily.dev/sources/devblogs)** · 7 min read · 1 upvotes · 0 comments

## Summary

Bacpac and dacpac files both serve database portability but differ in scope: a bacpac is a portable schema-plus-data copy limited to objects compatible with Azure SQL Database, while a dacpac is a deployment artifact supporting broader target platforms (SQL Server, Azure SQL Database, SQL database in Fabric) that can optionally include data. The post explains how bacpac export/import works versus native backups, how to inspect a bacpac's internal model.xml and BCP files, and walks through using SqlPackage CLI's extract and publish commands with options like ExtractAllTableData, AllowIncompatiblePlatform, and ExcludeObjectTypes to move databases between platforms.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://devblogs.microsoft.com/azure-sql/bacpac-and-dacpac-the-similarities-and-differences>

## Questions this post answers

### What is the difference between a bacpac and a dacpac file in SQL Server?

A bacpac is a portable copy of schema and data limited to objects supported in Azure SQL Database, used for export/import operations. A dacpac is primarily a deployment artifact supporting broader target platforms like SQL Server, Azure SQL Database, and SQL database in Fabric, and can optionally include data via extract with the table data option.

_Teams deciding between bacpac and dacpac for a migration can track SQL tooling changes on daily.dev._

### Why won't my SQL Server database export to a bacpac file?

A bacpac export fails when the database contains objects unsupported in Azure SQL Database, such as Windows logins, filestream columns, or SQL CLR elements. One workaround is copying the database and removing those unsupported objects before export, or using a dacpac extract instead, since dacpacs support broader target platforms without that restriction.

_Developers troubleshooting database export errors can follow SQL Server tooling updates on daily.dev._

### How do I include table data when extracting a dacpac file with SqlPackage?

Add the property /p:ExtractAllTableData=true to the sqlpackage extract command, optionally combined with /p:ExtractReferencedServerScopedElements=false to exclude server-scoped elements. This creates a dacpac containing both schema and data, similar to a bacpac, which can then be published with options like /p:AllowIncompatiblePlatform=true when moving between different database platforms.

_Engineers scripting database migrations can keep up with SqlPackage CLI options via daily.dev._

## Similar posts on daily.dev

- [From 20\+ seconds to 2 - faster SQL Database Project .dacpac deployments are finally here \(preview\)](https://daily.dev/posts/from-20-seconds-to-2---faster-sql-database-project-dacpac-deployments-are-finally-here-preview--v5pajiwa7) · We Are .NET · 0 upvotes · 0 comments

---

Tags: [#database](https://daily.dev/tags/database), [#azure](https://daily.dev/tags/azure), [#microsoft-sql-server](https://daily.dev/tags/microsoft-sql-server)

[View this post on daily.dev](https://daily.dev/posts/bacpac-and-dacpac-the-similarities-and-differences-gqomyrq66)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Bacpac and Dacpac, the similarities and differences","url":"https://daily.dev/posts/bacpac-and-dacpac-the-similarities-and-differences-gqomyrq66","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/bacpac-and-dacpac-the-similarities-and-differences-gqomyrq66"},"datePublished":"2026-09-02T13:54:20.658Z","dateModified":"2026-09-02T14:12:05.445Z","description":"Bacpac and dacpac files both serve database portability but differ in scope: a bacpac is a portable schema-plus-data copy limited to objects compatible with...","image":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/e0f9197d73849c0be40a7ff4cb116141?_a=AQAEuop","thumbnailUrl":"https://media.daily.dev/image/upload/f_auto,q_auto/v1/posts/e0f9197d73849c0be40a7ff4cb116141?_a=AQAEuop","isAccessibleForFree":true,"articleSection":"DevBlogs","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"DevBlogs","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/8f68b453325f482ebeb73fb780092713","url":"https://daily.dev/sources/devblogs"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/bacpac-and-dacpac-the-similarities-and-differences-gqomyrq66","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":1},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"database,azure,microsoft-sql-server","timeRequired":"PT7M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"DevBlogs","item":"https://daily.dev/sources/devblogs"},{"@type":"ListItem","position":3,"name":"Bacpac and Dacpac, the similarities and differences"}]}
{"@context":"https://schema.org","@type":"FAQPage","@id":"https://daily.dev/posts/bacpac-and-dacpac-the-similarities-and-differences-gqomyrq66#faq","mainEntity":[{"@type":"Question","name":"What is the difference between a bacpac and a dacpac file in SQL Server?","acceptedAnswer":{"@type":"Answer","text":"A bacpac is a portable copy of schema and data limited to objects supported in Azure SQL Database, used for export/import operations. A dacpac is primarily a deployment artifact supporting broader target platforms like SQL Server, Azure SQL Database, and SQL database in Fabric, and can optionally include data via extract with the table data option. Teams deciding between bacpac and dacpac for a migration can track SQL tooling changes on daily.dev."}},{"@type":"Question","name":"Why won't my SQL Server database export to a bacpac file?","acceptedAnswer":{"@type":"Answer","text":"A bacpac export fails when the database contains objects unsupported in Azure SQL Database, such as Windows logins, filestream columns, or SQL CLR elements. One workaround is copying the database and removing those unsupported objects before export, or using a dacpac extract instead, since dacpacs support broader target platforms without that restriction. Developers troubleshooting database export errors can follow SQL Server tooling updates on daily.dev."}},{"@type":"Question","name":"How do I include table data when extracting a dacpac file with SqlPackage?","acceptedAnswer":{"@type":"Answer","text":"Add the property /p:ExtractAllTableData=true to the sqlpackage extract command, optionally combined with /p:ExtractReferencedServerScopedElements=false to exclude server-scoped elements. This creates a dacpac containing both schema and data, similar to a bacpac, which can then be published with options like /p:AllowIncompatiblePlatform=true when moving between different database platforms. Engineers scripting database migrations can keep up with SqlPackage CLI options via daily.dev."}}]}
```

