Mapping
Automatically generate rules for moving data between any two schemas. Trained on billions of user decisions, Flatfile’s mapping engine can convert data in seconds.
Support even the most complex mapping requirements by creating your own data logic that’s written in code.
Trained on years of importing data files, Flatfile’s AI based column matching provides uncanny accuracy, and remembers what your customers do.
Easily combine or break apart data columns in any way you want with code-based transformations at the sheet, column, and cell level.
Go beyond mere column mapping with transformations that can even detect and re-create nested records in a flattened file.
Smart Rules that help you restructure data as needed, with recommendations from Flatfile’s AI model pre-trained on hundreds of millions of user mapping decisions.
Sometimes mapping is just as simple as recognizing fname as first_name. Flatfile can automatically alias source values to properties in the destination schema.
When your destination model has a single property to assign values to, and the source provides multiple, Flatfile knows how to provide either Array or Concat.
For collections of values, Flatfile can turn columns into an array of nested objects (or inversely, turn a collection of objects into a flattened structure).
Easily extract substrings from source data using exact pattern matching or use regular expressions for more complex needs.
Create text based values from multiple columns. For example, combine street, city, state and zip into a fully formatted address column.
Generate numerical values using your own custom formulas, utilizing multiple columns.
Apply default values wherever you’re missing data or have empty data.
Apply any standard text based transformations to your data such as case conversion, replacing special characters, or URL encoding.
Go beyond simple mapping rules with AI that understands the meaning and context of your data. Define what you want to do, and Flatfile takes care of the how.
AI-based mapping that knows how to categorize junior vs. senior job titles and that apples and oranges are fruit -- all using plain English.
Mapping that gets better with every user decision, unique to your business, trained on your own user data and interactions.
Users can set default values, discard values, or add new categories as custom, all with an easy to use editing interface.
Play with it
You can use Flatfile mapping wherever schema reformatting is required, whether it's in data pipelines like Airflow or Mage, API integrations, data conversion workflows, or import processes within your application.
from flatfile_mapping import get_mapping_rules, MappingProgram
source_fields = ["name", "zip"]
destination_fields = ["nombre", "postal code"]
rules = get_mapping_rules(source_fields, destination_fields)
program = MappingProgram(rules)
transformed_data = program.run(original_data)
import { getMappingRules, MappingProgram } from '@flatfile/mapping'
const sourceFields = ['name', 'zip']
const destinationFields = ['nombre', 'postal code']
const rules = await getMappingRules({ sourceFields, destinationFields })
const program = new MappingProgram(rules)
const transformedData = program.run(originalData)
curl --request POST --url $FLATFILE_BASE_API/mapping --header 'Accept: application/json' --header 'Content-Type: application/json' --header 'Authorization: Bearer $FLATFILE_API_KEY' -d '{
"source": {
"slug": "source",
"name": "source",
"sheets": [{
"name": "source-sheet",
"fields": [...]
More to love
Portal
Build a deeply configurable file import experience right in your application.
View PortalWorkbooks
Edit, validate, transform or integrate data into any workflow.
View WorkbooksProjects
Streamline complex data workflows across diverse stakeholders.
View Projects