HomeGuides › NAICS Code API: Classify Companies by Meaning

NAICS Code API: Classify Companies by Meaning

Keyword-based NAICS search breaks on colloquial input. Feed “we buy houses for cash and flip them” to a pure keyword ranker and the top hits are All Other Personal Services and Stationery Product Manufacturing — the words matched, the meaning didn't.

This API ranks by meaning: the description is embedded as a sentence vector and compared against all 1,012 six-digit 2022 NAICS codes plus the Census Bureau's ~20,000 official index activities, blended with keyword evidence so exact terminology still anchors the results. Every result carries a 0–100 match rating and the matched official activities, making the classification auditable.

Why keyword-only NAICS lookup falls short

The established option is keyword search over official titles and index terms. NAICS.com (the NAICS Association — the standard itself is maintained by the U.S. Census Bureau and OMB) offers a Keyword Search, Drilldown, and Details API with published plans: Free (500 credits), Starter at $50/month for 10,000 requests, Pro at $150/month for 100,000, Scale at $299/month for 250,000, with overage at $2–$5 per additional 1,000 calls. Matching is keyword-based on every plan. Their separate BizAPI, which appends codes to company records, is priced per successful match through a sales contact and capped at 3 requests per second. Third-party resellers of keyword NAICS search run around $30/month for 1,000 calls.

Keyword matching works when the searcher already knows the official terminology. It degrades on the most common real-world input: a company describing itself in its own words. Onboarding forms, CRM records, scraped descriptions, and capabilities statements rarely use Census phrasing, and a keyword ranker scores each word in isolation — so colloquial descriptions surface codes that share vocabulary while missing the industry entirely. Ranking by whole-description meaning, anchored by keyword evidence, handles both kinds of input.

Semantic matching in one call

POST the description to /match and the API returns ranked codes with a 0–100 rating, a strength band, the full sector→industry hierarchy, and the official Census activities that drove each match. The embedding model runs on our own server — the text goes to no third-party AI service and nothing is stored.

curl
curl -X POST "https://naics-code-finder.p.rapidapi.com/match" \
  -H "X-RapidAPI-Key: YOUR_KEY" \
  -H "X-RapidAPI-Host: naics-code-finder.p.rapidapi.com" \
  -H "Content-Type: application/json" \
  -d '{"text":"We fix furnaces and install heat pumps for homeowners","limit":3}'
Response (200, abbreviated)
{
  "count": 3,
  "results": [
    {
      "code": "238220",
      "title": "Plumbing, Heating, and Air-Conditioning Contractors",
      "rating": 58,
      "matchStrength": "moderate",
      "hierarchy": [
        { "code": "23", "title": "Construction" },
        { "code": "238", "title": "Specialty Trade Contractors" },
        { "code": "2382", "title": "Building Equipment Contractors" }
      ],
      "bestMatchingActivity": "Heating contractors",
      "matchedIndexTerms": ["Blower or fan, cooling and dry heating, installation", "Boiler, heating, installation"]
    }
  ]
}

Pricing comparison

The free tier covers 1,000 calls per month. PRO is $10/month for 100,000 calls — the same monthly volume NAICS.com's Pro plan sells for $150, a 15× difference, and semantic matching is included rather than keyword-only. At $30/month you get 1,000,000 calls; NAICS.com's largest published plan (Scale, $299/month) covers 250,000 with $2-per-1,000 overage, so a million keyword lookups there costs $1,799 — 60× the price. The $75 MEGA tier reaches 2,000,000 calls. Everything is self-serve through RapidAPI.

Keyword search is included for the cases where it is the right tool: GET /search gives instant IDF-ranked keyword results across every code level, suitable for autocomplete. GET /code returns the full official record (description, cross-references, hierarchy, child codes, index activities), and GET /similar returns the nearest codes by embedding for related-industries features.

Where teams use it

SAM.gov registration and government-contract bidding (match a capabilities statement to solicitation codes), KYB and insurance underwriting (classify applicants from their own descriptions), lead enrichment (tag imported company records at scale), marketplace onboarding (suggest an industry from whatever the business types), and analytics pipelines that normalize free-text industry fields into a standard taxonomy.

Run it in production

NAICS Code Finder has a permanent free tier — 1,000 requests a month, no credit card. Paid plans start at $5/month for 100,000 requests.

Get a free API key on RapidAPI ↗

Full endpoint reference →

FAQ

How is this different from the NAICS.com API?

Two ways. Matching: NAICS.com's lookup API is keyword search over official titles and terms; this API adds sentence-embedding semantic matching, so descriptions that share no words with the official title still find the right code — with keyword search included as a separate endpoint. Pricing: published flat tiers starting free (1,000 calls/month) and $10/month for 100,000 — 15× under NAICS.com's $150 Pro plan for the same volume.

Is this the official NAICS source?

The dataset is the official 2022 NAICS as published by the U.S. Census Bureau — all 2,125 codes, full descriptions, cross-references, and the ~20,000-entry index of business activities. The API itself is an independent product; it is not affiliated with the Census Bureau or the NAICS Association.

Does my text go to an AI provider?

No. The embedding model (MiniLM) runs in-process on our server. Text is processed in memory, never stored, and never forwarded — and there is no per-token fee.

How accurate is semantic matching?

Each result shows its evidence: a 0–100 rating, the semantic and keyword sub-scores, and the official Census activities that matched. Ratings of 75+ are typically unambiguous; when several codes rate closely, the returned descriptions let a human confirm in seconds.

Can I try it without an API key?

Yes — the free NAICS Code Lookup tool on this site runs the same /match endpoint in the browser, no signup.