Bulk Loading Guide

If you’ve already got a bunch of historical event data, you can load it into Keen IO using the publish_batch method in our Ruby Client, or the add_events method in our Python Client. You can also POST directly to our REST API using the Event Resource.

If you’d like to import events from CSV or JSON files check out keen-cli, a command-line interface for Keen IO. Here’s an example command that adds events from a CSV file into a collection called ‘signups’:

$ keen events:add --collection signups --file events.csv --csv


  1. Make sure you set the keen.timestamp property to your historical event’s timestamp. Otherwise Keen IO will assume your event happened at the time you posted it.
  2. We recommend posting in batches of 5,000 events or smaller.
Once the API acknowledges that your event has been stored, it may take up to 10 seconds before it will appear in query results.