Random Facts Api avatar

Random Facts Api

Pricing

from $0.01 / 1,000 results

Go to Apify Store
Random Facts Api

Random Facts Api

Access thousands of random facts, trivia, and interesting information via a fast API. Perfect for content creation, chatbots, apps, and educational tools. Get unique, engaging data instantly to boost user engagement and build smarter applications.

Pricing

from $0.01 / 1,000 results

Rating

0.0

(0)

Developer

Akash Kumar Naik

Akash Kumar Naik

Maintained by Community

Actor stats

0

Bookmarked

10

Total users

1

Monthly active users

17 days ago

Last modified

Features

Limited permissions

Share

Random Facts API is an Apify Actor that delivers thousands of random facts, trivia questions, and interesting information for content creation, chatbots, quiz apps, and educational projects — with single-fact, batch, daily-fact, and database-stats modes behind one simple input.

What Is Random Facts API?

Random Facts API is a pay-per-event facts API on the Apify platform. It fetches random facts from a database of 1000+ verified facts covering science, history, nature, technology, and more. Get a single fact instantly, download a batch of up to 10 facts, retrieve the featured fact of the day, or check database size and version info through stats mode — all from the same Actor.

Key Features

  • Random Facts — get one random fact instantly
  • Bulk Data — download up to 10 facts at once for offline use
  • Daily Fact — access the featured fact of the day
  • API Stats — view database size and version info
  • Verified database — 1000+ curated facts across science, history, nature, technology, and more
  • Clean JSON output — fact text plus source URL and a ready-to-embed HTML version
  • No platform costs — pay-per-event pricing means zero compute fees

Supported Modes

ModeWhat it returns
randomOne random fact from the database
batchUp to 10 facts in a single request
todayThe featured fact of the day
statsDatabase size and version info

Use Cases

  • Social media content — generate engaging posts and trivia threads
  • Chatbot training — add interesting responses to AI assistants and bots
  • Quiz & trivia apps — build question databases for games
  • Educational platforms — create learning materials and fun-facts sections
  • Data enrichment — enhance datasets with verified interesting facts
  • Website widgets — add "Did You Know?" sections to blogs and sites
  • Marketing campaigns — create curiosity-driven content

Input Parameters

ParameterTypeRequiredDefaultDescription
modestringYesrandomAPI mode: random, batch, today, or stats
limitintegerNo1Number of facts to fetch in batch mode (1–10)

Example input:

{
"mode": "batch",
"limit": 10
}

Sample Output

{
"text": "Octopuses have three hearts and blue blood.",
"source": "www.example.com",
"url": "https://www.example.com/facts/octopuses",
"html": "<blockquote>Octopuses have three hearts and blue blood.<footer>Source: www.example.com</footer></blockquote>"
}
FieldTypeDescription
textstringThe fact text
sourcestringThe source domain
urlstringThe source URL
htmlstringThe fact pre-formatted as an HTML blockquote

How to Use

  1. Open the Actor page on Apify Store and click Start Actor.
  2. Pick a mode — random for a single fact, batch to pull up to 10 facts, today for the featured fact, or stats for database info.
  3. Set limit (1–10) when using batch mode.
  4. Run the Actor and copy the fact from the Apify dataset, or export it as JSON, CSV, or Excel.

How to Use via API

cURL:

curl -X POST "https://api.apify.com/v2/acts/akash9078/random-facts-api/runs" \
-H "Authorization: Bearer YOUR_APIFY_TOKEN" \
-H "Content-Type: application/json" \
-d '{"mode": "random"}'

Python:

import requests
response = requests.post(
"https://api.apify.com/v2/acts/akash9078/random-facts-api/runs",
headers={"Authorization": "Bearer YOUR_APIFY_TOKEN"},
json={"mode": "random"},
)
print(response.json())

Node.js with Apify Client:

const { ApifyClient } = require('apify-client');
const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
const run = await client.actor('akash9078/random-facts-api').call({ mode: 'random' });
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);

Pricing

EventPrice
Fact Retrieved (fact-retrieved)$0.005 per fact

You only pay for facts you actually retrieve — there are no hourly compute costs or platform fees, and pricing stays predictable whether you fetch one fact or thousands.

Limitations

  • Batch mode returns a maximum of 10 facts per request
  • Rate limit: 5 requests per 30 seconds
  • Runs on Apify infrastructure with 128 MB of memory (Node.js 20+)

FAQ

How many facts can I fetch at once?

Up to 10 per request in batch mode. For larger volumes, call the Actor repeatedly via the Apify API.

Which modes are available?

random (one fact), batch (up to 10), today (featured fact of the day), and stats (database size and version info).

What does the output contain?

Each fact includes the plain text, the source domain and URL, and an HTML blockquote version ready to embed.

How is pricing calculated?

$0.005 per fact retrieved under the pay-per-event model — no runtime or platform fees.

Check out my other Apify Actors:


Built and maintained by akash9078 on the Apify platform.