Find stories in data

PyPI Changelog Python 3.x License discord mastodon: @datasette

Annotated version of this introductory video

Datasette is a tool for exploring and publishing data. It helps people take data of any shape, analyze and explore it, and publish it as an interactive website and accompanying API.

Datasette is aimed at data journalists, museum curators, archivists, local governments, scientists, researchers and anyone else who has data that they wish to share with the world. It is part of a wider ecosystem of 44 tools and 154 plugins dedicated to making working with structured data as productive as possible.

Try a demo and explore 33,000 power plants around the world, then follow the tutorial or take a look at some other examples of Datasette in action.

Then read how to get started with Datasette, subscribe to the newsletter and consider signing up for office hours for an in-person conversation about the project.

Exploratory data analysis

Import data from CSVs, JSON, database connections and more. Datasette will automatically show you patterns in your data and help you share your findings with your colleagues.

Instant data publishing

datasette publish lets you instantly publish your data to hosting providers like Google Cloud Run, Heroku or Vercel.

Rapid prototyping

Spin up a JSON API for any data in minutes. Use it to prototype and prove your ideas without building a custom backend.

Latest news and blog

30th November 2026 #

Datasette 1.0a45 introduces a significant new feature: support for displaying and editing many-to-many relationships directly from Datasette's table and row pages. The documentation has details and screenshots, or you can watch a demo video in the PR for the new feature.

15th November 2026 #

Datasette 0.65.6 and 1.0a43 are out. Both include a security fix for database downloads: a database registered with a route that differs from its name could be downloaded by actors who were denied access to it. Datasette 1.0a43 also fixes an issue that exposed private stored queries, and adds streaming output renderers and a new JSON format for individual rows, plus many bug fixes and smaller improvements.

16th September 2026 #

Datasette 0.65.5 and 1.0a40 are out, with a security fix for a table permisisons bypass. Datasette 1.0a40 also adds a mechanism for plugins to run background tasks.

11th September 2026

18th June 2026

11th June 2026

29th May 2026

24th May 2026

21st May 2026

13th May 2026

19th April 2026 #

Here's a new TIL on using SQL functions in Google Sheets to fetch data from Datasette.

15th April 2026 #

Datasette 1.0a27 changes how CSRF protection works in a way that simplifies form and API integration, and introduces a new RenameTableEvent for when a table is renamed by a SQL query.

18th March 2026 #

Datasette 1.0a26 adds a column_types system allowing columns to carry additional type information such as email or url, or extra types defined by plugins. This alpha also adds a UI for selecting and sorting visible columns on a table page.

25th February 2026 #

Datasette 1.0a25 adds write_wrapper() and register_token_handler() plugin hooks.

29th January 2026 #

Datasette 1.0a24 introduces a new await request.form(files=True) method for accepting file uploads, plus various other changes.

All news

Latest releases

1st December 2026

dogsheep-beta 0.11.1 - Build a search index across content from multiple SQLite database tables and run faceted searches against it using Datasette

  • Fix for compatibility with Datasette 1.0a44+.

datasette 1.0a45 - An open source multi-tool for exploring and publishing data

Many-to-many relationships

Datasette now displays many-to-many relationships on table and row pages, and provides tools for manipulating those relationships while editing a row. #3133

  • Pills for a junction table with extra columns are split in two: the related row on the left, and on the right a link to the junction table row showing the values of its first two text or number columns, such as a role, followed by "+N" for any others, with every value in its tooltip. See Pills.
  • Links can be added, removed and changed through plain junction tables and junction tables with extra columns (How relationships are detected). Unless they are configured, the links of relationships through repeatable junction tables, such as a reviews table with columns of its own, cannot be changed from the rows they link, only by editing the junction table's own rows, and these relationships are only shown if their foreign key is indexed.
  • New m2m table configuration key, for turning relationships off for a table, or choosing which ones to show, how to label them and which extra columns their pills show. The links of configured relationships can be edited from the rows they link whatever the kind of their junction table. See m2m.
  • New ?_m2m_size=, ?_m2m_truncate=0 and ?_nom2m=1 table and row arguments, for changing how many related rows are shown, showing extra column values in full and turning relationships off. See Special table arguments.
  • New ?_m2m.TABLE=value table filter, with __not, __in and __notin lookups, which filters a table by its rows' related rows through the junction table TABLE. The table page filter form shows these filters and can add them, searching the related table by label. See ?_m2m.TABLE=value and Filter and facet parameters.
  • New ?_facet_m2m=TABLE facet type, and m2m facets in configuration, which facet a table by its related rows. Datasette suggests these facets for tables that have a junction table. See Facet by many-to-many relationship.
  • The row edit and insert row dialogs can add and remove links, set and change the values of their extra columns, and create a related row from a label. The row and all of its link changes are saved in one transaction. See Editing links in the row dialogs.
  • The delete row dialog says what links to the row and what references it, and can delete its links and clear the foreign keys of rows that reference it, in the same transaction as the row. See Deleting rows.
  • The create table and alter table dialogs have a "Relationships" section, for creating relationships, which creates a junction table, and removing them, which drops it. See Creating and removing relationships.
  • New ?_extra=m2m and ?_extra=m2m_through extras for table and row JSON, and a ?_extra=foreign_key_details row extra. See Many-to-many relationships.
  • New APIs: POST /<database>/<table>/<row-pks>/-/m2m/<relationship> for adding, removing and changing links (Adding and removing many-to-many links), and GET /<database>/<table>/-/m2mfor listing a table's relationships (Listing a table's many-to-many relationships).
  • New options for existing write APIs: an m2m key for the row update, row insert and create tableAPIs, add_m2m and drop_m2m operations for the alter table API, which do not need alter-table on their own, and delete_m2m and clear_references keys for the row delete API.
  • Custom table templates get m2m_columns and row.m2m_cells, and row templates get m2m_sections. Relationship columns have the CSS classes m2m-col and m2m-col-NAME and a data-m2m="NAME" attribute. See Custom templates.
Breaking changes
  • Backwards incompatible: the ?_through={json} table filter has been removed, replaced by ?_m2m.TABLE.COLUMN=value. Unlike ?_through=, ?_m2m. only matches against foreign key columns. For now table pages redirect ?_through= to the equivalent ?_m2m. URL, in every format, and return a 400 error for a ?_through= that cannot be translated. The redirect will be removed in a later release. See the upgrade guide. (#621)
  • Backwards incompatible: the drop table API now only drops the table if confirm is the JSON boolean true. Previously any truthy value, such as "false", "no" or 1, dropped the table. Clients that send something other than a boolean now get a 400 error, confirm must be true or false, and the table is not dropped; false or no confirm still returns the preview.
  • Backwards incompatible: a request to the row delete API sent as application/json must now have a valid JSON body, otherwise it returns a 400 error. A request with no body, or a body of another content type, deletes the row as before.
Other features
  • The /-/jump endpoint has a new ?database= parameter, for returning only the items that belong to a database, such as its tables.
  • New ?_extra=row_paths table extra: the path of each row in rows, as used in its row page URL, in the same order. The insert and upsert APIs return the same row_paths list alongside rows when rows are returned.
  • The foreign_key_tables row extra, used for the "Referenced by" section of the row page, stops each count at 10,000, with a new count_capped key that is true if there are more, and counts under the facet_time_limit_ms time limit. If counting takes too long every count is null, rather than the list being empty.
  • Arbitrary SQL queries can now use explain and explain query plan with insert, update, delete and replace statements.
  • Datasette now depends on sqlite-utils>=4.2.2. With earlier versions the alter table API could lose a table's UNIQUE constraints, CHECK constraints and column collations, and made a nullable column NOT NULL when asked to keep it nullable, and the upsert API could overwrite values with NULL when rows in one request had different keys.
Bug fixes
  • Renaming a table using the alter table API or the alter table dialog now updates the foreign keys in other tables that reference it on every build of SQLite 3.26.0 or later. Previously those foreign keys were left pointing at the old name on builds where PRAGMA legacy_alter_table is on by default, including the SQLite that ships with macOS.
  • A rename-table event is no longer recorded when a single write drops one table and creates or rebuilds another. The new table can be given the storage that the dropped table had, which looked like a rename. A rename is now only reported if the table has the same definition before and after.
  • The schema pages, /<database>/-/schema and /<database>/<table>/-/schema with their .jsonand .md versions, find databases and tables whose names are tilde encoded in the URL, such as a database called release.v2 or a table name containing a / or a .. They returned a 404 for those databases and tables.
  • The foreign key targets endpoint used by the create and alter table dialogs no longer fails for a database with a table or view named pragma_table_info.
  • The list of suggestions shown by Datasette's autocomplete fields is attached to its input, so it is placed correctly with the on-screen keyboard open in iOS Safari. A search response that arrives after a suggestion was chosen, or the box was closed or emptied, is ignored.
  • Table pages no longer leave rows with a null primary key out of the count of rows before the current page, as used by ?_count=before, when the check for null primary keys runs out of time on a large table.
  • Long breadcrumbs in the header now wrap at word boundaries, including after each underscore in a database or table name, instead of breaking in the middle of a word. (#3128)

29th November 2026

sqlite-utils 4.2.2 - CLI tool and Python library for manipulating SQLite databases

Fixes for upsert() and upsert_all():

  • table.upsert_all() no longer overwrites existing values with NULL when records in the same batch have different keys. Each record now only updates the columns it provides. (#873)
  • table.upsert() and table.upsert_all() no longer raise IntegrityError when updating an existing row with a record that omits a NOT NULL column that has no default. An upsert that would create a new row without that column still raises the error. (#878)
  • SQL conversions= are now applied once when an upsert updates an existing row. Previously they were applied twice, so a conversion such as ? * 100 stored the wrong value. Thanks, Sanidhya Saluja. (#946, #947)

Fixes for full-text search:

  • table.enable_fts(..., fts_version="FTS4", create_triggers=True) now creates triggers that work. Previously any update or delete of an indexed row raised sqlite3.OperationalError: SQLlogic error. Existing FTS4 tables keep their old triggers until you run table.enable_fts(...,replace=True) or sqlite-utils enable-fts ... --replace. With the new FTS4 triggers a row that is skipped by UPDATE OR IGNORE is removed from the search index. Thanks, Caldera. (#922, #923)
  • table.detect_fts() no longer treats _ and % in a table name as wildcards, which could cause table.search() to use the search index belonging to a different table. Thanks, Ilya Khalafi. (#930, #931)
  • table.enable_fts(), table.search() and table.search_sql() now accept an iterator or generator of column names. Thanks, Syed Ahnaf Raza. Thanks, Pengyi Peng. (#902, #903, #942, #943)

Other fixes:

  • Carriage returns inside quoted CSV and TSV fields are now preserved on import. Previously \r\nand \r inside a quoted value were stored as \n. This affects sqlite-utils insert --csv, --tsv, sqlite-utils memory and rows_from_file(). Thanks, Agustin Saiz. (#895, #897)
  • table.transform() now preserves COLLATE clauses on columns. Previously a TEXT COLLATENOCASE column silently became case-sensitive after any transform. Thanks, Yewan Moon. (#954, #955)
  • table.transform(not_null={"column": False}) no longer adds a NOT NULL constraint to a column that was already nullable. (#944)
  • Calling table.convert() more than once with different callables that share a name, such as two dict.get methods, now runs the correct callable each time. Thanks, Zihan Dai. (#910, #911)
  • numpy integer and floating point scalars such as np.int64(5) are now stored as SQLite integers and floats. Previously they were stored as BLOB values. Thanks, Tanbir Hossain Ramim. (#876, #877)
  • table.analyze_column() and sqlite-utils analyze-tables now handle columns containing NULLvalues correctly. They previously reported wrong counts, could raise TypeError when counts were tied and could omit values from the results. analyze-tables --save now stores a JSON null for a null value where it used to store the string "None". (#887)
  • rows_from_file() now respects ignore_extras= and extras_key= for TSV files and for files where the format is detected automatically. (#892)
  • table.insert_all(..., truncate=True) and sqlite-utils insert --truncate now delete the existing rows when the new input is empty, for example a JSON [] or a CSV file with only a header row. Previously the existing rows were left in place. Thanks, Peter Olkhovets. (#935, #936)
  • sqlite-utils rows --limit 0 now returns no rows. Previously it returned every row in the table. Thanks, LucioLiu. (#964, #965)
  • rows_from_file() now closes the buffered reader it creates when detecting the format of a JSON file, avoiding a ResourceWarning.

28th November 2026

datasette-charts-pie 0.1a0

  • Initial release. Adds four chart types: pie, donut, sunburst, rose.

datasette-charts 0.5a0

Three new default chart types: #8

  • Calendar heatmap showing number of rows per day over a multi-year period.
  • Box plot showing the spread of numeric data across quartiles.
  • Active count showing how many rows are active over time based on start and end date columns.

27th November 2026

datasette-charts 0.4a0

Improved utilities for plugins that add new chart types, plus a website for the plugin at at charts.datasette.io.

  • New Writing chart type plugins documentation. It starts with a step-by-step tutorial that builds a lollipop chart plugin, then documents the Python classes, the rules for chart SQL, the column profile that suggestions are based on, how suggestions are scored and ranked, and the JavaScript renderer API. #7
  • Renderers for chart types from other plugins are now passed ctx.helpers - 22 utility function used by the built-in charts for theming, number formatting, axis labels, time buckets and laying out annotations. #7
  • Charts now work on tables named source, base, ranked and other names used by the plugin's own SQL. #5

25th November 2026

datasette-charts 0.3a0

This release adds chart annotations. Charts can now have labels, lines, and shaded areas attached to data on the chart. #4

  • Datasette Agent can make use of chart annotations as well, to label interesting points on the charts it displays.
  • Bar charts can now be made horizontal or vertical.
  • Editing and re-executing the SQL on a query page now refreshes the open chart from the new results.
  • Axis labels now adjust to fit better on small screens.

24th November 2026

datasette-charts 0.2a1

Minor UI improvements:

  • Collapsing the suggested charts section now leaves the chart visible.
  • Following a link to a chart opens it with the suggestions collapsed for that visit.
  • On table pages the panel now sits below the "4,235 rows where country = CHN" line.
  • The "Data" table under each chart has been replaced by Copy TSV and Copy CSV buttons.
  • Removed the "Chart this data" item from the table, view and query action menus.
  • More space between lines in chart tooltips.

datasette-charts 0.2a0

  • Now integrates with Datasette Agent. When both plugins are installed the agent gets a tool for drawing a chart in the conversation (linking to the chart builder in the panel) and a tool for suggesting charts for a table or query. Agent integration documentation. #1
  • New decade time unit, suggested for columns spanning centuries where yearly buckets would be too many. #2, #3
  • Line charts of data that skips buckets, such as one row per decade bucketed by year, now draw connected lines instead of isolated dots. #2

datasette-agent 0.7a1 - An LLM-powered agent assistant for Datasette

23rd November 2026

datasette-remote-metadata 0.2 - Periodically refresh Datasette metadata from a remote URL

  • This release is compatible with both Datasette 0.65.x and Datasette 1.0a44+.

datasette-cluster-map 0.19.1 - Datasette plugin that shows a map for any data with latitude/longitude columns

  • Compatible with Datasette 1.0a44.

datasette-psutil 0.2.1 - Datasette plugin adding a /-/psutil debugging endpoint

  • Fix for warnings with latest Datasette alpha.

datasette-agent-charts 0.1a3 - Observable Plot charts for Datasette Agent

datasette-agent 0.7a0 - An LLM-powered agent assistant for Datasette

All releases