
Trove
NewsSearch through the National Library of Australia collection of 1000s of digitised newspapers
π Documentation & Examples
Everything you need to integrate with Trove
π Quick Start Examples
// Trove API Example
const response = await fetch('https://trove.nla.gov.au/about/create-something/using-api', {
method: 'GET',
headers: {
'Content-Type': 'application/json'
}
});
const data = await response.json();
console.log(data);Dive into the treasure trove of information housed within the National Library of Australia with our comprehensive API. This API provides an unrivalled gateway to a diverse collection of thousands of digitised newspapers, enabling users to carry out text-based searches across a wealth of historical and contemporary publications. Whether you're involved in historical research or eager to learn more about Australia's past, the National Library of Australia API is a vital tool in your exploration of the country's printed media heritage and more.
Thanks to this APIβs user-friendly design and extensive capacities, you can pull highly specific data, conduct intricate searches, and access a comprehensive, detailed catalogue of Australia's digitised newspaper collections. Our API is also equipped to return search results in a wide range of formats including XML, JSON, and HTML rendering it highly convenient for web developers and researchers alike. You can access our thorough documentation here to start incorporating our API into your workflow.
Benefits of the National Library of Australia API:
- Search through an extensive collection of Australian digitised newspapers.
- Enjoy advanced querying capabilities for refined search results.
- Obtain search results in multiple data formats, including XML, JSON, and HTML.
- Integrate with other applications conveniently due to its interoperability with diverse systems.
- Leverage the comprehensive user manual and support available to utilise the API efficiently.
Below is a sample JavaScript code for executing a GET request to the National Library of Australia newspaper collection API:
var url = "https://api.trove.nla.gov.au/v2/result?key=YOUR_API_KEY&q=SEARCH_KEYWORD&zone=newspaper"
fetch(url, {
method: "GET",
})
.then(response => response.json())
.then(json => console.log(json))
.catch(err => console.log('Error: ', err));
Note: Replace 'YOUR_API_KEY' with your actual API Key and 'SEARCH_KEYWORD' with your search term.
How to Get a Trove API Key
Trove (National Library of Australia) requires a free API key, and the current version is v3 β the older v2 API is being retired, so build against v3.
- Create a free Trove account and sign in at https://trove.nla.gov.au
- Open your account's For developers area (Account β For developers / API keys).
- Request an API key for non-commercial use; it's issued to your account for free. (Commercial use requires contacting the NLA.)
- Send the key on each request via the
X-API-KEYheader (recommended) or akey=query parameter. The base URL ishttps://api.trove.nla.gov.au/v3.
const res = await fetch(
'https://api.trove.nla.gov.au/v3/result?q=Australia&category=newspaper&encoding=json',
{ headers: { 'X-API-KEY': 'YOUR_API_KEY' } }
);
const data = await res.json();
If you're following an older tutorial that uses https://api.trove.nla.gov.au/v2/result?...&key=YOUR_API_KEY, migrate to the v3 host and /v3/result path β the same key works, but v2 is deprecated. Requesting a key is free for personal and research projects.









