Using Databento DBN Files with the NanoConda Trade Simulator¶
The NanoConda Trade Simulator and backtesting engine now support Databento DBN files.
This integration enables cost-efficient, high-fidelity strategy testing without the complexity of working directly with raw PCAP files.
Compared to packet-level replay, DBN-based workflows are easier to manage, faster to configure, and better suited for rapid research iteration.
This workflow is especially useful for:
- Backtesting HFT strategies on complete market data sets and queue priority simulation.
- Practicing semi-automated or operator-assisted strategies.
- Training and onboarding new team members.
- Demonstrating trading systems to investors or stakeholders.
Why DBN Instead of Raw PCAP?¶
For most strategy development workflows, DBN offers:
- Faster setup and configuration
- Reduced storage requirements
- Lower data acquisition costs
- Simplified operational workflow
Raw PCAP replay remains useful for packet-level analysis, but DBN is generally the preferred approach for research, simulation, and operational testing.
Download and Prepare DBN Files¶
This guide explains how to download and prepare Databento DBN files for use with the NanoConda Trade Simulator.
Download DBN files¶
Begin by downloading data from the Databento Portal.
Navigate to the CME dataset catalog:

Select Required Schemas¶
After selecting your desired product(s), you must download two schemas for each required date range:
- MBO (Market By Order)
- Definition (Instrument definitions)
Both files must correspond to the same date range.

Choose Date Range¶
Select the appropriate historical date range:

Download Files¶
Once your order is processed, download the compressed .dbn.zst files:
mbo.dbn.zstdefinition.dbn.zst

These files will be used directly by the NanoConda DBN Feed Handler.
Configure Nanoconda XML file¶
After downloading the DBN files, update your NanoConda XML configuration.
Inside the <Ingester> node, set:
dbn-file→ path to your mbo.dbn.zst filedbn-instrument-file→ path to your definition.dbn.zst file
Example:
<Ingester
dbn-file="/data/glbx-mdp3-20260126.mbo.dbn.zst"
dbn-instrument-file="/data/glbx-mdp3-20260126.definition.dbn.zst"
dbn-speed="fast">
</Ingester>
Specify Instruments¶
You must also define which instruments to load by adding <Instrument> nodes.
You can subscribe to instruments using either:
- Exact symbols (including expirations), e.g. NQH6, ESH6
- Asset roots (without expirations), e.g. ES, NQ
When you specify an asset root, NanoConda automatically subscribes to all matching instruments present in the DBN definition file for the selected date range (for example, all listed expirations for that root).
<Instruments>
<!-- Subscribe to all ES expirations available in the DBN definition file -->
<Instrument symbol="ES" />
<!-- Subscribe to a specific contract -->
<Instrument symbol="NQH6" />
</Instruments>
This is useful when you want to backtest or simulate across multiple expirations without updating your configuration each time.
Sample Config¶
Example configuration for dbnbacktester:
<Feed logger="dbn-marketdata-CME.log" logger-cpu="-1" logger-level="trace" entitlement="XCME" >
<Ingester cpu="-1" dbn-file="/location/glbx1-mdp3-20260126.mbo.dbn.zst" dbn-instrument-file="/location/glbx-mdp3-20260125.definition.dbn.zst" />
<Instruments>
<Instrument symbol="ESH6" />
</Instruments>
</Feed>
Compile your Nanoconda Plugin¶
A sample plugin implementation is available in src/naco-app.cpp.
To compile the plugin as a shared object:
This will produce naco-plugin.so
Run the DBN Backtester with Your Plugin¶
After compiling the plugin, launch the dbnbacktester application and load your shared object:
-a dbnbacktesterselects the DBN backtesting engine-c dbn-playback.xmlspecifies your XML configuration-i naco-plugin.soloads your compiled strategy plugin
Your strategy will now execute inline while the DBN file is replayed.
DBN Publisher¶
In addition to inline backtesting, NanoConda provides the dbnpublisher application for publishing DBN market data directly to shared memory.
This mode mimics a production deployment:
- The DBN file is replayed through the NanoConda Feed Handler
- Normalized market data is published to shared memory
- Client algorithms connect as if consuming live market data
- Data is replayed at real-time speed.
This is useful when:
- Testing algorithms that consume shared memory directly
- Validating entitlement logic
- Running the GUI Simulator against historical data
- Reproducing production-like environments for debugging
To launch the publisher:
Once running, any authorized client (with proper <Entitlements> configuration) can attach to shared memory and consume the replayed market data and trade via Nanoconda GUI.
For detailed configuration instructions and shared memory setup, refer to the official documentation:
https://docs.nanoconda.com/databentodbn/
Summary¶
- Use
dbnbacktesterfor ultra-fast inline strategy backtesting. - Use
dbnpublisherto simulate a production shared-memory market data environment. - Ensure DBN market data and instrument definition files match by date.
- Always configure
<Entitlements>when testing shared-memory consumers.
Note
Please visit docs.nanoconda.com/quickstart to view full guide on how to run Nanoconda CLI for trade simulation.