Skip to main content

Import Data Seed to Firestore

Some app packages include seed JSON files for categories, vendors, listings, products, appointments, or demo content. Importing seed data helps the app show realistic content immediately after Firebase setup.

Quick Answer

Use seed data only in your own Firebase project, review the JSON files before importing, run the import tool or package script documented by the app, verify the created collections in Firestore, then customize the data for your product. Never import demo data blindly into a production database with real users.

Apps That Commonly Include Seed Data

Seed data is common in:

  • Store Locator;
  • Universal Listings;
  • Real Estate;
  • Food Delivery / Restaurant;
  • Appointments;
  • Taxi or marketplace-style apps;
  • app packages with category/vendor/listing collections.

Check the downloaded package for folders such as:

DataSeed/
dataSeed/
firebase/dataSeed/
scripts/seed/

1. Review the Seed Files

Open the JSON files before importing:

find . -iname "*.json" | rg "seed|categories|vendors|listings|products"

Confirm:

  • collection names match the app config;
  • IDs referenced by other documents exist;
  • image URLs are valid;
  • demo names and addresses are acceptable for your environment;
  • no private or production data is included.

2. Prepare Firebase

Before import:

  • create your Firebase project;
  • enable Firestore;
  • deploy Firestore rules and indexes if included;
  • make sure you are targeting the correct Firebase project.

From a Firebase folder:

firebase login
firebase use --add

3. Import the Data

Use the import script included with your app package when available. If the package points to a generic Firestore JSON import tool, install and run it from a temporary local folder, not from production app source.

Example command shape:

node import.js appointments_categories.json
node import.js appointments_vendors.json

The exact command depends on the tool shipped with your package. Prefer the package README when it includes a seed script.

4. Verify Collections

Open Firebase Console > Firestore Database and confirm:

  • expected collections were created;
  • document IDs look correct;
  • required fields are present;
  • referenced IDs match related collections;
  • app screens load the imported data.

Run the app and test the screens that depend on seed data.

5. Customize for Your Product

After import, replace demo content:

  • names and descriptions;
  • photos and media URLs;
  • addresses and coordinates;
  • categories and filters;
  • vendor or listing metadata;
  • prices and availability.

For repeatable updates, edit the JSON source files and re-import into a clean development/staging project before touching production.

Safety Checklist

  • You are importing into development or staging first.
  • The Firebase CLI points to the intended project.
  • You have reviewed collection names and document IDs.
  • You have backed up production data before any production import.
  • Firestore rules and indexes are deployed.
  • The app displays imported data after rebuild/reload.

Troubleshooting

ProblemFix
Data imports into the wrong projectRun firebase use and verify the active project before import.
App screens are emptyCheck collection names in app config and imported JSON.
Images do not loadReplace stale demo URLs or upload assets to your own Storage/CDN.
Missing index error appearsCreate the index from the Firebase error link or deploy indexes.
Import overwrites dataUse a staging project first and understand the import tool's overwrite behavior.

Next Steps