# Grants.gov Scraper: Federal Grant Opportunities, Deadlines (`best_celerytop/grants-gov-scraper`) Actor

Grants.gov scraper for US federal grant opportunities. Search by keyword, agency, category, eligibility, ALN and status. One row per funding opportunity: deadline, award ceiling and floor, total funding, eligible applicants, contact email and phone, attachments. Closing-soon filter. Official API.

- **URL**: https://apify.com/best_celerytop/grants-gov-scraper.md
- **Developed by:** [Konstantin Semin](https://apify.com/best_celerytop) (community)
- **Categories:** Business, Education, Lead generation
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.70 / 1,000 grant opportunities

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Grants.gov Scraper: US Federal Grants, Deadlines & Contacts

Search [Grants.gov](https://www.grants.gov), the official listing of US federal funding opportunities from 26 agencies, and get every matching opportunity as one clean row: title, number, agency, status, posting and closing dates, award ceiling and floor, estimated total funding, expected number of awards, cost sharing, eligible applicant types, eligibility text, full description, Assistance Listing (ALN/CFDA) programs, the agency contact with email and phone, and every attachment with a direct download link.

The Actor uses the official Grants.gov API. No login, no browser, no proxies, no API key.

### What you can do with it

- **Grant writers, nonprofits and universities**: find open grants in your field and see what closes in the next 30 or 60 days, with the contact to ask questions.
- **Consultants and grant databases**: build a complete, structured feed of federal opportunities by category, agency or applicant type.
- **Monitoring**: schedule a daily run with "Posted within the last 3 days" and push new opportunities to Slack, email or a sheet.
- **Research and journalism**: funding volumes by agency and program, forecasted opportunities, award sizes.
- **AI agents**: structured input for assistants that match organizations to funding.

### Input

| Field | Type | Description |
|---|---|---|
| `keywords` | array | Search terms, one search per line. Empty means browse by filters only. |
| `statuses` | array | `posted`, `forecasted`, `closed`, `archived`. Default: posted and forecasted. |
| `agencies` | array | Agency names, acronyms or codes: `NIH`, `Department of Energy`, `USDA`, `EPA`, `National Science Foundation`. A department includes its sub-agencies. |
| `fundingCategories` | array | Codes such as `HL` (Health), `ED` (Education), `ST` (Science and R\&D), `EN` (Energy), `AG` (Agriculture), `CD` (Community Development). |
| `eligibilities` | array | Applicant type codes, for example `12` (501(c)(3) nonprofits), `06` (public universities), `23` (small businesses), `21` (individuals), `99` (unrestricted). |
| `fundingInstruments` | array | `G` grant, `CA` cooperative agreement, `PC` procurement contract, `O` other. |
| `aln` | string | Assistance Listing Number, for example `93.393`. |
| `opportunityNumbers` | array | Specific opportunities by number, for example `RFA-CA-27-019`. |
| `postedWithinDays` | string | `3`, `7`, `14` ... `56`: only opportunities posted in that window. |
| `onlyNew` | boolean | Skip opportunities already returned by your earlier runs. For scheduled alerts. |
| `closingWithinDays` | integer | Only opportunities whose deadline falls between today and N days ahead. |
| `sortBy` | string | `relevance` (default), `closeDateAsc`, `closeDateDesc`, `openDateDesc`, `openDateAsc`, `title`, `agency`. |
| `includeDetails` | boolean | Add description, amounts, eligibility, contacts and attachments. Default `true`. |
| `maxItems` | integer | Maximum number of opportunities saved. Default `100`. |

#### Example input

```json
{
    "keywords": ["rural health"],
    "statuses": ["posted"],
    "eligibilities": ["12", "06"],
    "closingWithinDays": 60,
    "sortBy": "closeDateAsc",
    "maxItems": 200
}
```

### Output

One dataset item per opportunity.

```json
{
    "opportunityId": 359892,
    "opportunityNumber": "RFA-CA-27-019",
    "title": "Early-Stage Development of Informatics Technologies for Cancer Research and Management (U01 Clinical Trial Optional)",
    "url": "https://www.grants.gov/search-results-detail/359892",
    "status": "posted",
    "documentType": "synopsis",
    "category": "Discretionary",
    "agencyCode": "HHS-NIH11",
    "agency": "National Institutes of Health",
    "topAgency": "Department of Health and Human Services",
    "openDate": "2026-05-21",
    "postedDate": "2026-05-21",
    "closeDate": "2027-10-19",
    "closeDateExplanation": null,
    "archiveDate": "2027-12-19",
    "lastUpdatedDate": "2026-05-21",
    "alnNumbers": ["93.399", "93.395", "93.393", "93.394", "93.396"],
    "alnPrograms": [{ "number": "93.393", "title": "Cancer Cause and Prevention Research" }],
    "description": "The purpose of this Notice of Funding Opportunity (NOFO) is to ...",
    "awardCeiling": 300000,
    "awardFloor": 50000,
    "estimatedTotalFunding": 2400000,
    "expectedNumberOfAwards": null,
    "costSharingRequired": false,
    "applicantTypes": ["Native American tribal organizations", "Nonprofits having a 501(c)(3) status", "Small businesses"],
    "eligibilityDescription": "Refer to Section III. Eligibility Information in the NOFO for additional information on eligibility.",
    "fundingInstruments": ["Cooperative Agreement"],
    "fundingCategories": ["Health"],
    "contactName": "National Institutes of Health",
    "contactEmail": "nciitcr@mail.nih.gov",
    "contactPhone": "301-402-2541",
    "contactDescription": "NCI ITCR program",
    "additionalInfoUrl": null,
    "forecast": null,
    "attachments": [
        {
            "folder": "Full Announcement",
            "fileName": "RFA-CA-27-019-Full-Announcement.html",
            "description": "RFA-CA-27-019-Full-Announcement.html",
            "mimeType": "text/html;charset=UTF-8",
            "sizeBytes": 137060,
            "updatedAt": "2026-05-21",
            "url": "https://apply07.grants.gov/grantsws/rest/opportunity/att/download/352322"
        }
    ],
    "revision": 1,
    "versionHistoryCount": 1,
    "scrapedAt": "2026-11-12T08:00:00.000Z"
}
```

Forecasted opportunities carry a `forecast` object with the estimated posting and application due dates and the fiscal year. Amounts are in US dollars; fields the agency did not fill are `null`.

A `RUN_SUMMARY` record in the key-value store lists how many opportunities each search matched and how many were saved.

### Good to know

- **Deadline filter.** `closingWithinDays` works on the posted closing date and skips opportunities without one (some agencies publish "see announcement" instead of a date).
- **Several keywords** run as separate searches and are de-duplicated. Filters apply to every search.
- **Scale and speed.** Searches return 200 opportunities per request. With `includeDetails` on, one extra request per opportunity is made with four in parallel, so 1,000 opportunities take about three to four minutes.
- **Monitoring.** Switch on `onlyNew` and schedule a daily run: every run returns only opportunities you have not received before. The Actor remembers the IDs in a key-value store named `grants-gov-scraper-state` in your account; delete it to start over. Add `closingWithinDays: 14` on a weekly schedule for deadline reminders.
- **Polite by design.** Requests go to the public API with small pauses and a plain user agent.
- **Price.** $1 per 1,000 grant opportunities, no start fee; platform usage is included.
- **Works with n8n, Make, Zapier and AI agents.** The official Apify node for n8n runs this Actor and returns the rows inside a workflow, Make and Zapier use the Apify integration, and AI agents call it as a tool through the Apify MCP server.

### FAQ

**Does this cover state or private foundation grants?**
No. Grants.gov lists federal opportunities only.

**Can I download the attachments?**
Every attachment row has a direct `url`; most are PDFs, Word or HTML files that any download tool can fetch.

**How do I export Grants.gov search results to Excel?**
Run the search with your keywords and filters, then download the dataset as Excel, CSV or JSON.

**Does Grants.gov have an API?**
Yes, a public search API with no key. The Actor uses it and adds the full details of each opportunity.

**How can I get alerts for new federal grants?**
Schedule the Actor daily with `onlyNew` on and a short `postedWithinDays`; connect the dataset to email, Slack or a sheet.

**Can I use it from n8n or an AI agent?**
Yes. Start it through the official Apify node for n8n, the Make or Zapier integration, or the Apify MCP server, and read the rows back from the dataset.

**Something is missing or broken?**
Open an issue on the Issues tab and include the input you used.

### Disclaimer

This Actor is an independent tool. It is not affiliated with, endorsed by or sponsored by Grants.gov or the US Department of Health and Human Services. Opportunity data is public information published by the issuing agencies.

# Actor input Schema

## `keywords` (type: `array`):

Search terms, one search per line, for example `cancer research`, `rural broadband`, `youth mentoring`. Leave empty to browse by the filters below only.

## `statuses` (type: `array`):

`posted` are open now, `forecasted` are announced for later, `closed` and `archived` are past.

## `agencies` (type: `array`):

Agency names, acronyms or Grants.gov codes, for example `NIH`, `Department of Energy`, `USDA`, `EPA`, `National Science Foundation`. A department includes all its sub-agencies.

## `fundingCategories` (type: `array`):

Category of funding activity.

## `eligibilities` (type: `array`):

Keep opportunities open to any of these applicant types.

## `fundingInstruments` (type: `array`):

Type of award.

## `aln` (type: `string`):

Program number, for example `93.393` or `10.310`.

## `opportunityNumbers` (type: `array`):

Specific opportunities by number, for example `RFA-CA-27-019`.

## `postedWithinDays` (type: `string`):

Only opportunities posted recently. Useful for scheduled runs that watch for new grants.

## `onlyNew` (type: `boolean`):

Skip opportunities already returned by your earlier runs of this Actor. Switch on for scheduled runs that should deliver only what is new.

## `closingWithinDays` (type: `integer`):

Only opportunities whose application deadline is between today and this many days ahead. Leave empty for all.

## `sortBy` (type: `string`):

Order of the results.

## `includeDetails` (type: `boolean`):

Add the description, award ceiling and floor, total funding, expected number of awards, cost sharing, eligibility text, contact name, email and phone, and attachments with download links. One extra request per grant.

## `maxItems` (type: `integer`):

Maximum number of opportunities saved in the run.

## Actor input object example

```json
{
  "keywords": [
    "cancer research"
  ],
  "statuses": [
    "posted"
  ],
  "postedWithinDays": "",
  "onlyNew": false,
  "sortBy": "closeDateAsc",
  "includeDetails": true,
  "maxItems": 30
}
```

# Actor output Schema

## `grants` (type: `string`):

Grant opportunities with deadlines, amounts, eligibility, contacts and attachments.

## `runSummary` (type: `string`):

How many opportunities matched each search and were saved.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "keywords": [
        "cancer research"
    ],
    "statuses": [
        "posted"
    ],
    "sortBy": "closeDateAsc",
    "maxItems": 30
};

// Run the Actor and wait for it to finish
const run = await client.actor("best_celerytop/grants-gov-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "keywords": ["cancer research"],
    "statuses": ["posted"],
    "sortBy": "closeDateAsc",
    "maxItems": 30,
}

# Run the Actor and wait for it to finish
run = client.actor("best_celerytop/grants-gov-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "keywords": [
    "cancer research"
  ],
  "statuses": [
    "posted"
  ],
  "sortBy": "closeDateAsc",
  "maxItems": 30
}' |
apify call best_celerytop/grants-gov-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,best_celerytop/grants-gov-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/6LPOaXwlmxtMCU0Pm/builds/XYNvTTHLpTcrZEF13/openapi.json
