staticdata.dev
Menu
Datasets About Contact

IP Protocol Numbers

The assigned Internet Protocol numbers that go in the Protocol field of an IPv4 header and the Next Header field of an IPv6 header — 6 for TCP, 17 for UDP, 1 for ICMP, 58 for ICMPv6, and the rest. Each entry pairs the number with its keyword, full protocol name, and defining reference.

v1.0.0 MIT 151 records Updated 2026-10-05 stable Source:  IANA Assigned Internet Protocol Numbers

Quick fetch

Stable URL. CORS-enabled. No auth.

bash
curl https://staticdata.dev/v1/ip-protocol-numbers.json

Or use as a typed import: import { ipProtocolNumbers } from "https://staticdata.dev/v1/ip-protocol-numbers.ts"

Formats

  • JSON 20.2 KB

    /v1/ip-protocol-numbers.json

    Open

    min: 15.8 KB · /v1/ip-protocol-numbers.min.json

  • CSV 8.6 KB

    /v1/ip-protocol-numbers.csv

    Open
  • TypeScript 20.4 KB

    /v1/ip-protocol-numbers.ts

    export const ipProtocolNumbers

    type IpProtocolNumber = (typeof ipProtocolNumbers)[number]

    Open

Schema

Each record in the dataset has the following shape.

Schema
Field Type Description Example
number number Protocol number (0–255) 6
keyword string | null Short keyword TCP
protocol string Full protocol name Transmission Control
reference string | null Defining RFC or reference RFC9293

Preview

First 10 records.

Data preview
numberkeywordprotocolreference
0HOPOPTIPv6 Hop-by-Hop OptionRFC8200
1ICMPInternet Control MessageRFC792
2IGMPInternet Group ManagementRFC1112
3GGPGateway-to-GatewayRFC823
4IPv4IPv4 encapsulationRFC2003
5STStreamRFC1190, RFC1819
6TCPTransmission ControlRFC9293
7CBTCBTTony_Ballardie
8EGPExterior Gateway ProtocolRFC888, David_Mills
9IGPany private interior gateway (used by Cisco for their IGRP)Internet_Assigned_Numbers_Authority

Showing 10 of 151. View full data:  JSON · CSV

Fetch examples

Drop-in snippets in five languages.

curl
curl -sSL https://staticdata.dev/v1/ip-protocol-numbers.json | jq '.[0]'
JavaScript
import type { IpProtocolNumber } from "https://staticdata.dev/v1/ip-protocol-numbers.ts";

const res = await fetch("https://staticdata.dev/v1/ip-protocol-numbers.min.json");
if (!res.ok) throw new Error(`Fetch failed: ${res.status}`);
const ipProtocolNumbers: IpProtocolNumber[] = await res.json();
console.log(ipProtocolNumbers[0]);
Python
import urllib.request, json

with urllib.request.urlopen("https://staticdata.dev/v1/ip-protocol-numbers.min.json") as r:
    ipProtocolNumbers = json.load(r)

print(ipProtocolNumbers[0])
Go
package main

import (
	"encoding/json"
	"fmt"
	"net/http"
)

func main() {
	resp, err := http.Get("https://staticdata.dev/v1/ip-protocol-numbers.min.json")
	if err != nil { panic(err) }
	defer resp.Body.Close()

	var data []map[string]any
	if err := json.NewDecoder(resp.Body).Decode(&data); err != nil {
		panic(err)
	}
	fmt.Println(data[0])
}
Rust
use serde_json::Value;

fn main() -> Result<(), Box<dyn std::error::Error>> {
    let body = ureq::get("https://staticdata.dev/v1/ip-protocol-numbers.min.json").call()?.into_string()?;
    let data: Vec<Value> = serde_json::from_str(&body)?;
    println!("{:?}", data.first());
    Ok(())
}

Sources and methodology

The data comes from the IANA Assigned Internet Protocol Numbers registry. This is the 8-bit field that identifies the next-layer protocol carried in an IP packet — the IPv4 Protocol field and the IPv6 Next Header field share the same number space.

Only individually assigned numbers are included; unassigned and reserved ranges are omitted, so a number absent from this dataset is either unassigned or reserved. keyword and reference are nullable because a few historical assignments have no registered keyword or citation. Number 255 is reserved, and 253/254 are designated for experimentation and testing.

Versioning

URLs under /v1/ are stable: field names and types will not change in a way that breaks consumers. Values can be corrected or records added when the upstream source changes; schema-incompatible updates ship under a new version path. See the ip-protocol-numbers changelog for this dataset's history.

Related datasets

More Web datasets