Hii Alan,
Thank you reaching us regarding the issue.
It sounds like you're facing some challenges with your Azure Static Web App's database connection due to the retirement of the current feature. Here’s what you should consider to keep your app functioning properly:
Steps to Continue Using Database Connections:
- Configuration File: Ensure that you have a
staticwebapp.database.config.jsonfile in your configuration folder. This file is essential for database connections. The default folder name isswa-db-connections, but if you've configured a different name, make sure it aligns with yourdata_api_locationin the build workflow file. - Database Type: If you're using Azure Cosmos DB, you need to reference a
staticwebapp.database.schema.gqlfile within your configuration. This schema file must define your database's structure. - Migration: Since the Azure Static Web Apps database connection feature will be retired on November 30, 2025, it's recommended to migrate to a self-hosted Data API builder instance on Azure Container Apps.
- Local Development: If you're developing locally, you can use the Azure Static Web Apps CLI to manage your database connections. Make sure to start the CLI correctly by using the
--data-api-locationoption pointing to your configuration folder. - Post-Migration Support: If you have issues specific to configuring or developing with the Data API builder post-migration, consider reaching out to the Data API Builder GitHub forum for assistance.
Reference:
https://learn.microsoft.com/en-us/azure/static-web-apps/database-overview
https://learn.microsoft.com/en-us/azure/static-web-apps/database-azure-sql?tabs=bash&pivots=static-web-apps-rest#configure-the-static-web-app
https://learn.microsoft.com/en-us/azure/data-api-builder/overview
Kindly let us know if the above comment helps or you need further assistance on this issue.
Please "upvote" if the information helped you. This will help us and others in the community as well.