How to load data from MongoDb to Weaviate
Learn how to use Airbyte to synchronize your MongoDb data into Weaviate within minutes.


Building your pipeline or Using Airbyte
Airbyte is the only open source solution empowering data teams to meet all their growing custom business demands in the new AI era.
- Inconsistent and inaccurate data
- Laborious and expensive
- Brittle and inflexible
- Reliable and accurate
- Extensible and scalable for all your needs
- Deployed and governed your way
Start syncing with Airbyte in 3 easy steps within 10 minutes



Take a virtual tour
Demo video of Airbyte Cloud
Demo video of AI Connector Builder
Setup Complexities simplified!
Simple & Easy to use Interface
Airbyte is built to get out of your way. Our clean, modern interface walks you through setup, so you can go from zero to sync in minutes—without deep technical expertise.
Guided Tour: Assisting you in building connections
Whether you’re setting up your first connection or managing complex syncs, Airbyte’s UI and documentation help you move with confidence. No guesswork. Just clarity.
Airbyte AI Assistant that will act as your sidekick in building your data pipelines in Minutes
Airbyte’s built-in assistant helps you choose sources, set destinations, and configure syncs quickly. It’s like having a data engineer on call—without the overhead.
What sets Airbyte Apart
Modern GenAI Workflows
Move Large Volumes, Fast
An Extensible Open-Source Standard
Full Control & Security
Fully Featured & Integrated
Enterprise Support with SLAs
What our users say

Raman Singh
Predictable, straightforward pricing model that simplified budgeting and significantly reduced overall spend

Chase Zieman

“Airbyte helped us accelerate our progress by years, compared to our competitors. We don’t need to worry about connectors and focus on creating value for our users instead of building infrastructure. That’s priceless. The time and energy saved allows us to disrupt and grow faster.”

Rupak Patel
"With Airbyte, we could just push a few buttons, allow API access, and bring all the data into Google BigQuery. By blending all the different marketing data sources, we can gain valuable insights."
How to Sync to Manually
Begin by ensuring that both your MongoDB and Weaviate instances are properly set up and running. For MongoDB, this means having access to the database with the necessary credentials. For Weaviate, make sure it is deployed and accessible, with the schema designed to accommodate the data you plan to migrate.
Use MongoDB’s native tools to export data. The `mongoexport` utility can be used to export data to a JSON or CSV file. For example, use a command like:
```
mongoexport --db yourDatabase --collection yourCollection --out data.json
```
This command exports the specified collection to a JSON file called `data.json`.
After exporting, review the JSON structure to ensure it aligns with Weaviate's requirements. Weaviate uses a certain schema, so you might need to transform your data to match the schema, such as adjusting field names or data types. You can use a script, written in Python or another language, to parse and transform the JSON data.
Before importing data, define a Weaviate schema that reflects the structure of your data. This involves specifying classes, properties, and data types. Use Weaviate's RESTful API to create the schema. An example API call in JSON format might look like:
```json
{
"class": "YourClass",
"properties": [
{
"name": "propertyName",
"dataType": ["string"]
}
]
}
```
Use a tool like `curl` to send the schema to Weaviate.
Develop a script to read the transformed JSON data and insert it into Weaviate. You can use Python with `requests` library to interact with Weaviate’s REST API. The script should iterate over the JSON records and use the API to create objects in Weaviate, like:
```python
import json
import requests
with open('transformed_data.json', 'r') as file:
data = json.load(file)
for record in data:
response = requests.post(
'http://your-weaviate-instance/objects',
json={
"class": "YourClass",
"properties": record
}
)
print(response.status_code, response.json())
```
Execute the script to start importing data into Weaviate. Ensure that the script handles any potential errors, such as network issues or data validation errors. Monitor the output to verify that the data is being successfully inserted.
After the import process, verify that the data in Weaviate matches the original data in MongoDB. You can perform sample queries using Weaviate’s API to ensure that the data is correctly stored and accessible. Check for any discrepancies and resolve them by re-importing or adjusting the data as needed.
By following these steps, you can successfully migrate data from MongoDB to Weaviate without relying on third-party connectors or integrations.