# Udemy Course Scraper 🎓 (`shahidirfan/udemy-course-scraper`) Actor

Extract comprehensive course data from Udemy with ease. Scrape course titles, instructors, ratings, reviews, prices, discounts, duration, curriculum, last updated date, language, enrollment count, and more. Perfect for market research, price tracking, analysis, and educational data collection.

- **URL**: https://apify.com/shahidirfan/udemy-course-scraper.md
- **Developed by:** [Shahid Irfan](https://apify.com/shahidirfan) (community)
- **Categories:** Developer tools, Automation, Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.00 / 1,000 results

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/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

### What does Udemy Course Scraper do?

Udemy Course Scraper collects structured course data from Udemy search results. Add a Udemy search URL or a keyword, choose how many courses you want, and the Actor returns course titles, URLs, instructors, prices, ratings, review counts, images, duration, lectures, levels, badges, and learning outcomes.

Use it for course market research, competitor tracking, pricing analysis, content catalog building, learning trend monitoring, and AI or RAG workflows that need clean Udemy course datasets.

***

### Why use Udemy Course Scraper?

- **Course search datasets** - Build structured datasets from Udemy keyword, search, topic, category, or course-style URLs.
- **Clean output** - Empty and unavailable values are omitted instead of saved as null fields.
- **Pricing coverage** - Collect current price, discount price, list price, amount, and currency when available.
- **Pagination support** - Control result count, page size, and page caps for small tests or larger exports.
- **Automation-ready data** - Export to JSON, CSV, Excel, XML, Google Sheets, webhooks, or your own API workflow.

***

### What data can you extract from Udemy?

| Field | Description |
|-------|-------------|
| `course_id` | Numeric Udemy course ID |
| `title` | Course title |
| `headline` | Course headline or subtitle |
| `course_url` | Direct Udemy course URL |
| `enroll_url` | Course enrollment URL when available |
| `learn_url` | Course learning URL when available |
| `image_url` | Main course image URL |
| `thumbnail_url` | Smaller course thumbnail URL |
| `instructors` | Instructor names |
| `instructor_ids` | Udemy instructor IDs |
| `rating` | Average course rating |
| `reviews_count` | Number of ratings or reviews |
| `is_free` | Whether the course is free |
| `price` | Current displayed price |
| `price_amount` | Numeric current price amount |
| `currency` | Price currency |
| `list_price` | Listed price before discount |
| `list_price_amount` | Numeric list price |
| `discount_price` | Discount price string |
| `duration_seconds` | Course duration in seconds |
| `lectures_count` | Number of lectures |
| `practice_test_questions_count` | Number of practice test questions |
| `level` | Course level |
| `locale` | Course locale |
| `updated_on` | Last update date shown for the course |
| `badges` | Course badges such as bestseller labels |
| `learning_outcomes` | Published learning outcomes |
| `is_practice_test_course` | Whether the result is a practice-test course |
| `is_google_partner_collection` | Google partner collection flag when available |
| `career_accelerator_ids` | Related career accelerator IDs when available |
| `curriculum_match_titles` | Matching curriculum item titles when available |
| `search_keyword` | Keyword used for the search |
| `search_page` | Search page where the course was found |
| `source` | Source platform name |
| `scraped_at` | Timestamp for when the record was collected |

***

### How to use Udemy Course Scraper

1. Open the Actor on Apify.
2. Enter a Udemy URL in `startUrl` or add a search term in `keyword`.
3. Set `results_wanted` and `max_pages`.
4. Choose a sort order if needed.
5. Run the Actor and download the dataset.

If both `startUrl` and `keyword` are provided, `keyword` is used for the search.

***

### Input Parameters

| Parameter | Type | Required | Default | Description |
|-----------|------|----------|---------|-------------|
| `startUrl` | String | No | `https://www.udemy.com/courses/search/?src=ukw&q=python` | Udemy search, topic, category, or course URL |
| `keyword` | String | No | - | Search keyword. Takes priority over the URL keyword |
| `results_wanted` | Integer | No | `20` | Maximum number of courses to save |
| `max_pages` | Integer | No | `5` | Maximum search result pages to request |
| `sort_order` | String | No | `relevance` | Sort order: `relevance`, `reviews`, or `rating` |
| `proxyConfiguration` | Object | No | `{ "useApifyProxy": false }` | Optional proxy settings for cloud runs |

***

### Output Data

| Field | Type | Description |
|-------|------|-------------|
| `course_id` | Integer | Numeric Udemy course ID |
| `title` | String | Course title |
| `headline` | String | Course headline |
| `course_url` | String | Direct course URL |
| `image_url` | String | Course image URL |
| `instructors` | Array | Instructor names |
| `rating` | Number | Average course rating |
| `reviews_count` | Integer | Number of ratings or reviews |
| `price` | String | Current displayed price |
| `currency` | String | Price currency |
| `list_price` | String | Listed price before discount |
| `duration_seconds` | Integer | Course duration in seconds |
| `lectures_count` | Integer | Number of lectures |
| `practice_test_questions_count` | Integer | Number of practice test questions |
| `level` | String | Course level |
| `updated_on` | String | Last course update date |
| `badges` | Array | Course badges |
| `learning_outcomes` | Array | Published learning outcomes |
| `search_keyword` | String | Keyword used for the search |
| `search_page` | Integer | Search page where the course was found |
| `source` | String | Source platform |
| `scraped_at` | String | Collection timestamp |

***

### Usage Examples

#### Keyword Search

Collect the first 20 Udemy courses for a keyword:

```json
{
  "keyword": "python",
  "results_wanted": 20,
  "max_pages": 5,
  "sort_order": "relevance"
}
```

#### Search URL

Use a Udemy search URL directly:

```json
{
  "startUrl": "https://www.udemy.com/courses/search/?src=ukw&q=data%20science",
  "results_wanted": 50,
  "max_pages": 5
}
```

#### Topic or Category URL

Use a Udemy topic or category-style URL and let the Actor extract the search term:

```json
{
  "startUrl": "https://www.udemy.com/topic/python/",
  "results_wanted": 100,
  "max_pages": 10,
  "sort_order": "reviews"
}
```

***

### Sample Output

```json
{
  "course_id": 2776760,
  "title": "100 Days of Code: The Complete Python Pro Bootcamp",
  "headline": "Master Python by building 100 projects in 100 days. Learn data science, automation, build websites, games and apps!",
  "course_url": "https://www.udemy.com/course/100-days-of-code",
  "image_url": "https://img-c.udemycdn.com/course/480x270/2776760_f176_10.jpg",
  "instructors": ["Dr. Angela Yu, Developer and Lead Instructor"],
  "rating": 4.6663103103637695,
  "reviews_count": 432124,
  "price": "$9.99",
  "price_amount": 9.99,
  "currency": "USD",
  "list_price": "$59.99",
  "list_price_amount": 59.99,
  "duration_seconds": 204484,
  "lectures_count": 604,
  "level": "ALL_LEVELS",
  "updated_on": "2026-06-12",
  "badges": ["Bestseller"],
  "search_keyword": "python",
  "search_page": 1,
  "source": "Udemy",
  "scraped_at": "2026-08-04T09:55:00.000Z"
}
```

***

### Tips for Best Results

- Use a specific keyword such as `python`, `data science`, `excel`, or `project management`.
- Start with `results_wanted` set to `20` for a quick test run.
- Increase `max_pages` when requesting more results than one search page can return.
- Use `reviews` when you want established courses with larger review counts.
- Use `rating` when you want highly rated course results.
- Check the dataset preview before scheduling large recurring runs.

***

### Integrations

- **Google Sheets** - Send Udemy course data to spreadsheets.
- **Webhooks** - Trigger downstream workflows after each run.
- **Make or Zapier** - Connect course datasets to no-code automations.
- **API access** - Retrieve datasets from your own applications.
- **CSV and Excel exports** - Download course data for analysis and reporting.

***

### Frequently Asked Questions

#### Can I scrape Udemy courses by keyword?

Yes. Add a keyword such as `python`, `excel`, or `machine learning`, and the Actor will collect matching Udemy course results.

#### Can I use a Udemy URL instead of a keyword?

Yes. You can use a Udemy search URL, topic URL, category-style URL, or course-style URL. When a keyword is also provided, the keyword takes priority.

#### Does the output include prices?

Yes. The dataset includes current price, list price, discount price, amount, and currency when Udemy publishes those values for the course.

#### Why are some fields missing?

Some Udemy courses do not publish every field. The Actor omits empty values instead of saving nulls.

#### Can I run this Actor on a schedule?

Yes. Apify schedules can run the Actor hourly, daily, weekly, or at another interval for course monitoring.

#### Can I export Udemy course data to CSV or Excel?

Yes. Apify datasets can be exported to CSV, Excel, JSON, XML, RSS, and other supported formats.

#### Is it legal to scrape Udemy courses?

Scraping public web data can be legal, but you are responsible for complying with applicable laws, Udemy's terms, privacy rules, and your intended use of the data.

***

### Related Actors

- [Coursera Scraper](https://apify.com/shahidirfan/coursera-scraper)
- [EdX Course Scraper](https://apify.com/shahidirfan/edx-course-scraper)
- [Skillshare Courses Scraper](https://apify.com/shahidirfan/skillshare-courses-scraper)

***

### Support

For issues, feature requests, or custom Actor work, use the Issues tab on the Actor page or contact the developer through Apify.

***

### Legal Notice

This Actor is designed for legitimate collection of publicly available Udemy course data. Do not use it to collect private information, bypass access controls, spam Udemy, or violate applicable terms or laws.

# Actor input Schema

## `startUrl` (type: `string`):

Udemy search, topic, category, or course URL. If keyword is also provided, keyword takes priority.

## `keyword` (type: `string`):

Search keyword. This takes priority over keywords extracted from the URL.

## `results_wanted` (type: `integer`):

Maximum number of courses to save.

## `max_pages` (type: `integer`):

Maximum number of search result pages to request.

## `sort_order` (type: `string`):

Udemy search sorting.

## `proxyConfiguration` (type: `object`):

Optional proxy settings for cloud runs.

## Actor input object example

```json
{
  "startUrl": "https://www.udemy.com/courses/search/?src=ukw&q=python",
  "keyword": "python",
  "results_wanted": 20,
  "max_pages": 5,
  "sort_order": "relevance",
  "proxyConfiguration": {
    "useApifyProxy": false
  }
}
```

# Actor output Schema

## `overview` (type: `string`):

No description

# 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 = {
    "startUrl": "https://www.udemy.com/courses/search/?src=ukw&q=python",
    "keyword": "python",
    "results_wanted": 20,
    "max_pages": 5,
    "sort_order": "relevance"
};

// Run the Actor and wait for it to finish
const run = await client.actor("shahidirfan/udemy-course-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 = {
    "startUrl": "https://www.udemy.com/courses/search/?src=ukw&q=python",
    "keyword": "python",
    "results_wanted": 20,
    "max_pages": 5,
    "sort_order": "relevance",
}

# Run the Actor and wait for it to finish
run = client.actor("shahidirfan/udemy-course-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 '{
  "startUrl": "https://www.udemy.com/courses/search/?src=ukw&q=python",
  "keyword": "python",
  "results_wanted": 20,
  "max_pages": 5,
  "sort_order": "relevance"
}' |
apify call shahidirfan/udemy-course-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,shahidirfan/udemy-course-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/AwZEIxhYF1bvSNE7Z/builds/hbAF82R59mHpRk8fm/openapi.json
