The list of highlights
Up to 10 highlights of the profile, each with its title and cover image, and how many highlights the profile has in total.
Enter an Instagram username or profile URL to see the story highlights of a public profile, then open one to see its photos and videos. No Instagram login needed, and the API calls that return the same data are shown below the result.
Up to 10 highlights per profile. Public profiles only.
nasa or @nasa, or its address (instagram.com/nasa).Up to 10 highlights of the profile, each with its title and cover image, and how many highlights the profile has in total.
Open a highlight to see its photos and videos with the date each one was posted. The media links come from Instagram and stop working after a while, so save what you need.
The viewer reads what a public profile shows anyone who opens it. A private account's highlights aren't public, so they can't be shown.
Meta's Instagram API is built for professional (business or creator) accounts you own or manage: publishing, comments, insights. It is not a way to read another account's story highlights. For the highlights of any public profile, the SocialAPIs API returns them with one API key.
The list is two calls to the SocialAPIs REST API: the profile's ID, then its highlights. Opening a highlight is one more call. Use the same calls to archive a brand's highlights or watch competitors' new ones, from any language or from n8n, Make and Zapier.
GET /instagram/user/id with username, then GET /instagram/profile/highlights with user_id: 2 credits for the list. GET /instagram/highlight/details with highlight_id: 1 credit per highlight opened. Your key goes in the x-api-token header, never in the URL.
# Step 1: the profile's pk
curl -G "https://api.socialapis.io/instagram/user/id" \
--max-time 100 \
--fail-with-body \
-H "x-api-token: $SOCIALAPIS_API_KEY" \
--data-urlencode "username=nasa"
# Step 2: the highlights (user_id = the pk from step 1)
curl -G "https://api.socialapis.io/instagram/profile/highlights" \
--max-time 100 \
--fail-with-body \
-H "x-api-token: $SOCIALAPIS_API_KEY" \
--data-urlencode "user_id=528817151"
# Step 3: the photos and videos of one highlight
curl -G "https://api.socialapis.io/instagram/highlight/details" \
--max-time 100 \
--fail-with-body \
-H "x-api-token: $SOCIALAPIS_API_KEY" \
--data-urlencode "highlight_id=18145966027591735"import os
import requests
HEADERS = {"x-api-token": os.environ["SOCIALAPIS_API_KEY"]}
# Step 1: the profile's pk
response = requests.get(
"https://api.socialapis.io/instagram/user/id",
headers=HEADERS,
params={
"username": "nasa",
},
timeout=100,
)
response.raise_for_status()
print(response.json())
# Step 2: the highlights (user_id = the pk from step 1)
response = requests.get(
"https://api.socialapis.io/instagram/profile/highlights",
headers=HEADERS,
params={
"user_id": "528817151",
},
timeout=100,
)
response.raise_for_status()
print(response.json())
# Step 3: the photos and videos of one highlight
response = requests.get(
"https://api.socialapis.io/instagram/highlight/details",
headers=HEADERS,
params={
"highlight_id": "18145966027591735",
},
timeout=100,
)
response.raise_for_status()
print(response.json())// Node 18+, as an ES module (e.g. main.mjs)
async function get(url, params) {
const query = new URLSearchParams(params).toString();
const response = await fetch(query ? `${url}?${query}` : url, {
headers: { "x-api-token": process.env.SOCIALAPIS_API_KEY },
signal: AbortSignal.timeout(100000),
});
if (!response.ok) throw new Error(`HTTP ${response.status}: ${await response.text()}`);
return response.json();
}
// Step 1: the profile's pk
let data = await get("https://api.socialapis.io/instagram/user/id", {
username: "nasa",
});
console.log(data);
// Step 2: the highlights (user_id = the pk from step 1)
data = await get("https://api.socialapis.io/instagram/profile/highlights", {
user_id: "528817151",
});
console.log(data);
// Step 3: the photos and videos of one highlight
data = await get("https://api.socialapis.io/instagram/highlight/details", {
highlight_id: "18145966027591735",
});
console.log(data);import java.net.URI;
import java.net.URLEncoder;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.nio.charset.StandardCharsets;
import java.time.Duration;
import java.util.Map;
import java.util.stream.Collectors;
public class Main {
private static final HttpClient CLIENT = HttpClient.newBuilder()
.connectTimeout(Duration.ofSeconds(10))
.build();
public static void main(String[] args) throws Exception {
// Step 1: the profile's pk
String body = get("https://api.socialapis.io/instagram/user/id", Map.of(
"username", "nasa"));
System.out.println(body);
// Step 2: the highlights (user_id = the pk from step 1)
body = get("https://api.socialapis.io/instagram/profile/highlights", Map.of(
"user_id", "528817151"));
System.out.println(body);
// Step 3: the photos and videos of one highlight
body = get("https://api.socialapis.io/instagram/highlight/details", Map.of(
"highlight_id", "18145966027591735"));
System.out.println(body);
}
static String get(String url, Map<String, String> params) throws Exception {
String query = params.entrySet().stream()
.map(e -> URLEncoder.encode(e.getKey(), StandardCharsets.UTF_8) + "="
+ URLEncoder.encode(e.getValue(), StandardCharsets.UTF_8))
.collect(Collectors.joining("&"));
HttpRequest request = HttpRequest.newBuilder(URI.create(query.isEmpty() ? url : url + "?" + query))
.header("x-api-token", System.getenv("SOCIALAPIS_API_KEY"))
.timeout(Duration.ofSeconds(100))
.GET()
.build();
HttpResponse<String> response = CLIENT.send(request, HttpResponse.BodyHandlers.ofString());
if (response.statusCode() / 100 != 2) {
throw new RuntimeException("HTTP " + response.statusCode() + ": " + response.body());
}
return response.body();
}
}package main
import (
"fmt"
"io"
"log"
"net/http"
"net/url"
"os"
"time"
)
func main() {
// Step 1: the profile's pk
body, err := get("https://api.socialapis.io/instagram/user/id", url.Values{
"username": {"nasa"},
})
if err != nil {
log.Fatal(err)
}
fmt.Println(string(body))
// Step 2: the highlights (user_id = the pk from step 1)
body, err = get("https://api.socialapis.io/instagram/profile/highlights", url.Values{
"user_id": {"528817151"},
})
if err != nil {
log.Fatal(err)
}
fmt.Println(string(body))
// Step 3: the photos and videos of one highlight
body, err = get("https://api.socialapis.io/instagram/highlight/details", url.Values{
"highlight_id": {"18145966027591735"},
})
if err != nil {
log.Fatal(err)
}
fmt.Println(string(body))
}
func get(endpoint string, params url.Values) ([]byte, error) {
if len(params) > 0 {
endpoint += "?" + params.Encode()
}
req, err := http.NewRequest(http.MethodGet, endpoint, nil)
if err != nil {
return nil, err
}
req.Header.Set("x-api-token", os.Getenv("SOCIALAPIS_API_KEY"))
client := &http.Client{Timeout: 100 * time.Second}
resp, err := client.Do(req)
if err != nil {
return nil, err
}
defer resp.Body.Close()
body, err := io.ReadAll(resp.Body)
if err != nil {
return nil, err
}
if resp.StatusCode/100 != 2 {
return nil, fmt.Errorf("HTTP %d: %s", resp.StatusCode, body)
}
return body, nil
}Set SOCIALAPIS_API_KEY to your key first (export SOCIALAPIS_API_KEY=…). Step 1's data.pk is the user_id of step 2; step 2's data.highlights has each highlight's id, title and cover; step 3's data.highlight.items has each story's image_versions, video_versions and taken_at. Calls that return data are charged, including empty results; errors (4xx/5xx) are not charged.
Enter the username (for example nasa) or the profile address (instagram.com/nasa) into the viewer above. It lists the profile's highlights; pick one to see its photos and videos. You don't log in to Instagram at any point.
No. A private account's highlights are visible only to its approved followers, so there is nothing public to show. The viewer works for public profiles only.
The viewer reads the public highlights from our servers without any Instagram account of yours, so there is no account of yours to appear in a viewers list.
Up to 10 highlights per profile. Inside a highlight, visitors without an account see the first stories and the total count; signed in, you get up to 50 stories per highlight.
Each photo and video opens in a new tab from Instagram's own servers, where your browser can save it. Those links expire after a while. Respect the owner's copyright: viewing public content is one thing, reposting it without permission is another.
Without an account you get a few free lookups a day to try it. Signed in, the list of highlights is two API calls (2 credits) and opening one highlight is one call (1 credit) on your own account. Calls that return data are charged, including empty results; errors (4xx/5xx) are not charged. The free plan includes 200 calls a month, no credit card; paid plans start at $4.99 a month.
Use the API: GET /instagram/user/id with username returns the profile's pk, GET /instagram/profile/highlights with user_id (that pk) returns the highlights, and GET /instagram/highlight/details with highlight_id returns the stories. The code below is the exact set of calls this viewer makes.
SocialAPIs (socialapis.io) is a public Facebook and Instagram data API. Free plan: 200 calls a month, no credit card. Paid plans from $4.99 a month. One x-api-token header.
Instagram follower count · Instagram engagement rate · Facebook Page viewer