# Gab Posts Scraper (`maximedupre/gab-posts-scraper`) Actor

Find public Gab posts by keyword, post URL, or profile, or collect public profiles by username or URL. Get post text, authors, dates, engagement, media, links, mentions, tags, and source context in an Apify dataset.

- **URL**: https://apify.com/maximedupre/gab-posts-scraper.md
- **Developed by:** [Maxime Dupré](https://apify.com/maximedupre) (community)
- **Categories:** Social media, Marketing, News
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.75 / 1,000 posts

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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

### 🔍 Find public Gab posts and profiles

For researchers, analysts, and developers, this Actor finds public Gab posts by keyword, post URL, or profile. It also collects public profiles by username or profile URL. It saves structured post and profile data, including text, authors, dates, engagement, media, links, and the input context that first found each row. You can review public Gab activity in a dataset instead of copying posts and profiles by hand.

- Find a public Gab profile and its available account details with **[Gab Profile Scraper](https://apify.com/maximedupre/gab-posts-scraper/examples/gab-profile-scraper)**.
- Search public Gab posts for a word or phrase with **[Gab Search Scraper](https://apify.com/maximedupre/gab-posts-scraper/examples/gab-search-scraper)**.
- Collect public posts linked from a Gab profile with **[Gab Posts Scraper](https://apify.com/maximedupre/gab-posts-scraper/examples/gab-posts-scraper)**.
- Review public Gab post text, authors, and engagement with **[Gab Social Media Scraper](https://apify.com/maximedupre/gab-posts-scraper/examples/gab-social-media-scraper)**.
- Start a public Gab data collection with **[Gab Scraper](https://apify.com/maximedupre/gab-posts-scraper/examples/gab-scraper)**.

#### 📦 Returned Gab post and profile data

Each run writes one row for each eligible public post or profile to the default dataset. Post rows include text, author details, publication time, engagement counts, media, shared links, mentions, tags, and source context when Gab provides them. Profile rows include the public profile URL, username, display name, biography, account counts, profile images, verification status, and source context when available.

When the same public post or profile is found through another submitted keyword, URL, username, or similar value, the first eligible match is saved and later matches are ignored. The `sourceContext` object records only the one value that first produced the saved row. Fields that Gab does not expose may be absent.

#### ▶️ Run a Gab collection

1. Choose `Posts` or `Profiles` as the result type.
2. For posts, choose `Keywords`, `Post URLs`, `Profile username`, or `Profile URL`. For profiles, choose `Username` or `Profile URL`.
3. Enter the values for the method you chose. Other fields stay visible but are ignored.
4. For a direct post URL, turn on `Include thread context` when you also want other available public posts from that post's thread.
5. Set `Maximum results` to cap the run. Leave it empty to return all available results until the source is exhausted. The schema has no upper bound for this field.
6. Start the run and open `datasetItems` in the Output panel.

Only public Gab content that the source makes available can be returned. Private, deleted, blocked, or otherwise unavailable content is outside the Actor's scope. No Gab source login or API key is required for public data.

#### ⚙️ Input

**Input fields**

| Field | Type | What it does |
|---|---|---|
| `resultType` | string | Required. Chooses whether this run returns public Gab posts or public Gab profiles. |
| `postOptions` | object | Sets how to find public posts. Search by keywords, retrieve direct post URLs, or get posts linked from a profile username or profile URL. Fields for other choices stay visible and are ignored. |
| `postOptions.findPostsBy` | string | Chooses one post method: `keywords`, `postUrls`, `profileUsernames`, or `profileUrls`. |
| `postOptions.keywords` | array of strings | One or more words or phrases to search for public Gab posts. Used when `findPostsBy` is `keywords`. |
| `postOptions.postUrls` | array of objects | One or more public Gab post URLs. Used when `findPostsBy` is `postUrls`. |
| `postOptions.postUrls[].url` | string URL | One public Gab post URL. |
| `postOptions.includeThreadContext` | boolean | For `postUrls`, includes other available public posts from each post's thread. It is ignored for other post methods. |
| `profileOptions` | object | Sets how to find public profiles. Use a username or a profile URL. Fields for the other choice stay visible and are ignored. |
| `profileOptions.findProfilesBy` | string | Chooses `profileUsernames` or `profileUrls` for a profile run. |
| `profileUsernames` | array of strings | One or more public Gab usernames. Used for profile posts or profile runs that use usernames. |
| `profileUrls` | array of objects | One or more public Gab profile URLs. Used for profile posts or profile runs that use profile URLs. |
| `profileUrls[].url` | string URL | One public Gab profile URL. |
| `maxItems` | integer | Stops after this many results. Leave it empty to return all available results until the source is exhausted. The schema has no upper bound. |

Fields for a different method remain in the form but are ignored. Use separate runs when you need a different result type or method.

**Input example**

This example is copied from the public input of a successful current-beta default-input run:

```json
{
  "resultType": "posts",
  "postOptions": {
    "findPostsBy": "keywords",
    "keywords": [
      "gab"
    ],
    "includeThreadContext": false
  },
  "maxItems": 20
}
```

#### 🧾 Output

The Output panel provides `datasetItems`, a string link to the default dataset overview. Each saved row has one of the two shapes below. Fields that are not required may be absent when Gab does not expose them.

**Dataset link**

| Field | Type | What it does |
|---|---|---|
| `datasetItems` | string URL | Opens the successful post and profile rows from this run in the default dataset. |

**Post row**

| Field | Type | What it does |
|---|---|---|
| `recordType` | string | Constant value `post` for a post row. |
| `post` | object | Required. Holds the public post data. |
| `post.url` | URL string | Required. The canonical public URL of the post. |
| `post.text` | string | Required. The full public text of the post when Gab exposes it. |
| `post.author` | object | Required. Public identity details for the post author. |
| `post.author.username` | string | Required. The author's public Gab username. |
| `post.author.displayName` | string | The author's public display name when available. |
| `post.author.profileUrl` | URL string | The author's canonical public profile URL when available. |
| `post.publishedAt` | date-time string | The source publication time when available. |
| `post.engagement` | object | Available public engagement counts. |
| `post.engagement.likes` | integer | Public like count when available. |
| `post.engagement.replies` | integer | Public reply count when available. |
| `post.engagement.reposts` | integer | Public repost count when available. |
| `post.media` | array of objects | Public media attached to the post when available. |
| `post.media[].url` | URL string | Required within a media object. The public media URL. |
| `post.media[].mediaType` | string | Media type reported by the source when available. |
| `post.media[].altText` | string | Media alternative text when available. |
| `post.sharedLinks` | array of objects | Useful public link previews found in the post when available. |
| `post.sharedLinks[].url` | URL string | Required within a shared-link object. The URL shared in the post. |
| `post.sharedLinks[].title` | string | Public title of the shared link when available. |
| `post.sharedLinks[].description` | string | Public description of the shared link when available. |
| `post.sharedLinks[].imageUrl` | URL string | Public preview image URL when available. |
| `post.sharedLinks[].siteName` | string | Public site name shown for the shared link when available. |
| `post.mentions` | array of objects | Public accounts mentioned in the post when available. |
| `post.mentions[].username` | string | Required within a mention object. The public Gab username mentioned in the post. |
| `post.mentions[].profileUrl` | URL string | Public profile URL for the mentioned account when available. |
| `post.tags` | array of strings | Public tags associated with the post when available. |
| `post.sourceContext` | object | Required. The input context that first produced this row. |
| `post.sourceContext.type` | string | Required. One of `keyword`, `postUrl`, `profileUsername`, `profileUrl`, or `thread`. |
| `post.sourceContext.value` | string | Required. The single keyword, URL, username, or post URL that first produced this row. |

**Example post row**

This unshortened row is copied from a successful current-beta keyword run and is shown as returned:

```json
{
  "recordType": "post",
  "post": {
    "url": "https://gab.com/Mike8877/posts/117343232928215624",
    "text": "@Kimmie_social Welcome to gab, kimmie.",
    "author": {
      "username": "Mike8877",
      "displayName": "Mike8877",
      "profileUrl": "https://gab.com/Mike8877"
    },
    "sourceContext": {
      "type": "keyword",
      "value": "gab"
    },
    "publishedAt": "2026-09-27T13:27:19.171Z",
    "engagement": {
      "likes": 0,
      "replies": 0,
      "reposts": 0
    },
    "mentions": [
      {
        "username": "Kimmie_social",
        "profileUrl": "https://gab.com/Kimmie_social"
      }
    ]
  }
}
```

**Profile row**

| Field | Type | What it does |
|---|---|---|
| `recordType` | string | Constant value `profile` for a profile row. |
| `profile` | object | Required. Holds the public profile data. |
| `profile.url` | URL string | Required. The canonical public profile URL. |
| `profile.username` | string | Required. The public Gab username. |
| `profile.displayName` | string | The public display name when available. |
| `profile.bio` | string | The public profile biography when available. |
| `profile.counts` | object | Available public account counts. |
| `profile.counts.followers` | integer | Public follower count when available. |
| `profile.counts.following` | integer | Public following count when available. |
| `profile.counts.posts` | integer | Public post count when available. |
| `profile.avatarUrl` | URL string | Public profile avatar URL when available. |
| `profile.coverImageUrl` | URL string | Public profile cover image URL when available. |
| `profile.isVerified` | boolean | Whether Gab marks the profile as verified. |
| `profile.sourceContext` | object | Required. The input context that first produced this row. |
| `profile.sourceContext.type` | string | Required. One of `profileUsername` or `profileUrl`. |
| `profile.sourceContext.value` | string | Required. The single username or profile URL that first produced this row. |

**Example profile row**

This unshortened row is copied from a successful current-beta profile run and is shown as returned:

```json
{
  "recordType": "profile",
  "profile": {
    "url": "https://gab.com/Dissenter",
    "username": "Dissenter",
    "sourceContext": {
      "type": "profileUsername",
      "value": "Dissenter"
    },
    "displayName": "Dissenter",
    "bio": "The News Magazine from Gab AI",
    "counts": {
      "followers": 1455,
      "following": 0,
      "posts": 3995
    },
    "avatarUrl": "https://m3.gab.com/accounts/avatars/001/015/816/original/d691919b7f17d4d2.png",
    "coverImageUrl": "https://m3.gab.com/accounts/headers/001/015/816/original/3d4e63687ffefe96.png",
    "isVerified": true
  }
}
```

#### 💳 Pricing

This Actor uses pay-per-event pricing. Each saved public post row costs $0.00175, and each saved public profile row costs $0.00175. A run with no saved rows has no post or profile row event.

| Charged row | Price | What is billed |
|---|---:|---|
| Post | $0.00175 | One saved public post row. |
| Profile | $0.00175 | One saved public profile row. |

#### 🔌 Integrations

Open the dataset in the Apify Console, download it from the run, or use the Apify API, schedules, and webhooks in your workflow.

https://www.youtube.com/watch?v=bNACk1\_S\_6w\&list=PLObrtcm1Kw6MUrlLNDbK9QRg8VDJg0gOW\&index=4

#### ❓ FAQ

##### What happens when the same post matches more than one keyword?

The first eligible match is saved. Later matches are ignored, and `sourceContext` keeps the keyword that first produced the row. The row does not collect later matches.

##### Can I retrieve one post and include its thread context?

Yes. Choose `Post URLs`, enter the public post URL, and turn on `Include thread context`. The run can add other available public posts from that post's public thread.

##### Can I collect posts and profile rows in one run?

No. Choose `Posts` or `Profiles` for each run. A post run can find posts by keyword, direct post URL, or profile, while a profile run returns profile rows. Use separate runs when you need both shapes.

##### Why is a field missing from a row?

Gab may not expose every field for every public post or profile. Optional fields are left out when the source does not provide them.

##### Do I need a Gab login or API key?

No. The Actor uses public Gab data and does not require source authentication. It cannot return private, deleted, blocked, or otherwise unavailable content.

##### Does an empty result limit return every Gab post?

No. Leaving `maxItems` empty returns all available results until the source is exhausted. It does not promise every later match or every historical post that Gab may have.

### 📝 Changelog

**v0.0** (27-09-2026)

- Initial release.

### 🆘 Support

For issues, questions, or feature requests, [file a ticket](https://console.apify.com/actors/maximedupre~gab-posts-scraper/issues) and I'll fix or implement it in less than 24h 🫡

### 🔗 Related Actors

- [Bluesky Posts Search Scraper](https://apify.com/maximedupre/bluesky-search): Search public Bluesky posts and profiles by keyword or post URL.
- [Truth Social Posts Scraper](https://apify.com/maximedupre/truth-social-posts): Collect public Truth Social posts from profile URLs.
- [VK Posts Scraper](https://apify.com/maximedupre/vk-posts-scraper): Collect public VK posts from profile and community walls or direct URLs.
- [Facebook User Posts Scraper](https://apify.com/maximedupre/facebook-user-posts-scraper): Collect public Facebook posts from profiles, Pages, or known post URLs.
- [Twitter Scraper](https://apify.com/maximedupre/twitter-scraper): Collect public X posts, profiles, and network records.

**Made with ❤️ by Maxime Dupré**

# Actor input Schema

## `resultType` (type: `string`):

Choose whether this run returns public Gab posts or public Gab profiles.

## `postOptions` (type: `object`):

Choose how to find public Gab posts. Search by keywords, retrieve direct post URLs, or get posts linked from a profile username or profile URL. Fields for other choices stay visible and are ignored.

## `profileOptions` (type: `object`):

Choose how to find public Gab profiles. Use a username or a profile URL. Fields for the other choice stay visible and are ignored.

## `profileUsernames` (type: `array`):

Enter one or more public Gab usernames. Used when Find posts by is Profile username or Find profiles by is Username. If another method is selected, this field is ignored.

## `profileUrls` (type: `array`):

Enter one or more public Gab profile URLs. Used when Find posts by is Profile URL or Find profiles by is Profile URL. If another method is selected, this field is ignored.

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

Stop after this many results. Leave it empty to return all available results until the source is exhausted.

## Actor input object example

```json
{
  "resultType": "posts",
  "postOptions": {
    "findPostsBy": "keywords",
    "keywords": [
      "gab"
    ],
    "includeThreadContext": false
  },
  "maxItems": 20
}
```

# Actor output Schema

## `datasetItems` (type: `string`):

Open the successful posts and profiles from this run.

# 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 = {
    "resultType": "posts",
    "postOptions": {
        "findPostsBy": "keywords",
        "keywords": [
            "gab"
        ],
        "includeThreadContext": false
    },
    "maxItems": 20
};

// Run the Actor and wait for it to finish
const run = await client.actor("maximedupre/gab-posts-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 = {
    "resultType": "posts",
    "postOptions": {
        "findPostsBy": "keywords",
        "keywords": ["gab"],
        "includeThreadContext": False,
    },
    "maxItems": 20,
}

# Run the Actor and wait for it to finish
run = client.actor("maximedupre/gab-posts-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 '{
  "resultType": "posts",
  "postOptions": {
    "findPostsBy": "keywords",
    "keywords": [
      "gab"
    ],
    "includeThreadContext": false
  },
  "maxItems": 20
}' |
apify call maximedupre/gab-posts-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,maximedupre/gab-posts-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/tJVL4400y6QURLY4l/builds/nkacuQv5OKbXlQBEr/openapi.json
