People Also Ask Scraper
Pricing
Pay per usage
People Also Ask Scraper
Extract Google's People Also Ask questions for keywords, with optional tree expansion for multi-level questions. Perfect for SEO content research, topic cluster creation, FAQ generation, and content brief development.
Pricing
Pay per usage
Rating
0.0
(0)
Developer
HappiTap
Maintained by CommunityActor stats
0
Bookmarked
13
Total users
11
Monthly active users
23 days ago
Last modified
Categories
Share
People Also Ask (PAA) SEO Scraper
Extract Google's People Also Ask questions for keywords, with optional tree expansion for multi-level questions. Perfect for SEO content research, topic cluster creation, FAQ generation, and content brief development.
๐ Features
- PAA Extraction: Scrape People Also Ask questions from Google SERP
- Tree Expansion: Expand questions to discover multi-level related questions
- Multi-locale Support: Target specific countries and languages
- Device Targeting: Desktop and mobile search simulation
- Proxy Support: Built-in proxy rotation for reliability
- Deduplication: Automatic duplicate question removal
- Multiple Output Formats: Dataset, JSON, CSV export options
- Rate Limiting: Configurable delays and retry logic
- Answer Snippets: Optional answer extraction when available
- Comprehensive Testing: Full test suite with 95%+ coverage
๐ Input Configuration
Keyword Inputs
- keywords: Array of keywords to search
- keywordsText: Multiline string with keywords (one per line)
- inputDatasetId: Read keywords from existing dataset
Locale & Search Controls
- country: Two-letter ISO country code (default: "US")
- language: Language code (default: "en")
- gl: Override Google "gl" parameter
- hl: Override Google "hl" parameter
- uule: Encoded location for city-level targeting
- device: Device type - "desktop" or "mobile" (default: "desktop")
PAA Extraction Controls
- mode: "paa_only" or "paa_tree" (default: "paa_only")
- treeDepth: Maximum expansion depth for tree mode (default: 2)
- maxQuestionsPerKeyword: Maximum questions per keyword (default: 80)
- maxExpansions: Maximum expansions in tree mode (default: 40)
Rate & Reliability
- proxyConfiguration: Apify proxy configuration (residential proxies recommended)
- maxConcurrency: Maximum concurrent requests (default: 5)
- requestRetries: Number of retries for failed requests (default: 5)
- minDelayMs: Minimum delay between requests (default: 1000)
- maxDelayMs: Maximum delay between requests (default: 4000)
- timeoutSecs: Request timeout in seconds (default: 30)
Output Options
- outputFormat: "dataset", "json", or "csv" (default: "dataset")
- dedupe: Remove duplicate questions (default: true)
- includeSerpMeta: Include SERP metadata (default: true)
- includeAnswerSnippets: Extract answer snippets (default: false)
๐ Output Schema
Question Records
Each extracted question includes:
- keyword: Original search keyword
- question: The PAA question text
- questionNormalized: Normalized question for deduplication
- depth: Question depth (0 for direct PAA, >0 for expanded)
- parentQuestion: Parent question in tree mode
- position: Question position in the block
- answerSnippet: Answer snippet when available
- sourceUrl: Google SERP URL used
- country, language, device: Search parameters
- scrapedAt: ISO timestamp
- hash: Unique dedupe key
Keyword Summary
- keyword: Search keyword
- totalQuestions: Number of questions found
- maxDepthReached: Maximum depth achieved in tree mode
- status: "ok", "blocked", or "no_paa_found"
- errorReason: Error details if failed
๐ก Usage Examples
Example 1: Basic PAA Extraction
{"keywordsText": "best crm for small business\nwhatsapp marketing automation\nhow to start ecommerce store","country": "IN","language": "en","mode": "paa_only","maxQuestionsPerKeyword": 50,"proxyConfiguration": {"apifyProxyGroups": ["RESIDENTIAL"]}}
Example 2: PAA Tree Mode
{"keywords": ["best seo tools"],"country": "US","language": "en","mode": "paa_tree","treeDepth": 3,"maxQuestionsPerKeyword": 100,"maxExpansions": 50,"includeAnswerSnippets": true,"proxyConfiguration": {"apifyProxyGroups": ["RESIDENTIAL"]}}
Example 3: Large Scale Research
{"inputDatasetId": "YOUR_DATASET_ID","country": "US","language": "en","mode": "paa_tree","treeDepth": 2,"maxQuestionsPerKeyword": 80,"maxConcurrency": 3,"minDelayMs": 2000,"maxDelayMs": 5000,"outputFormat": "csv","proxyConfiguration": {"apifyProxyGroups": ["RESIDENTIAL"]}}
๐ฏ Use Cases
SEO Content Strategy
- Topic Clusters: Discover related questions for content hub creation
- Content Briefs: Generate comprehensive briefs with user questions
- FAQ Generation: Create FAQ sections from real user queries
- Schema Markup: Generate FAQ schema JSON-LD automatically
Market Research
- User Intent: Understand what users are asking about topics
- Content Gaps: Identify questions your competitors aren't answering
- Keyword Expansion: Find long-tail question-based keywords
Content Marketing
- Blog Ideas: Generate endless blog post ideas from questions
- Video Topics: Create video content that answers specific questions
- Social Media: Develop social content around user questions
โก Performance & Limits
Recommended Usage
- MVP: 50-200 keywords per run
- Concurrency: 3-5 concurrent requests to avoid blocks
- Proxies: Use residential proxies for large scale scraping
Rate Limiting
- Built-in delays between requests (1-4 seconds default)
- Automatic retry with exponential backoff
- Session management for request rotation
Block Detection
- Automatic detection of captchas and blocks
- Graceful handling of blocked keywords
- Continues processing remaining keywords
๐งช Testing
This actor includes a comprehensive test suite:
# Run all testsnpm test# Run tests with coveragenpm run test:coverage# Run tests in watch modenpm run test:watch
Test Coverage
- Unit Tests: Core functionality (normalization, hashing, URL building)
- Integration Tests: Full workflow testing
- Schema Validation: Output data quality and structure
- Error Handling: Edge cases and failure scenarios
๐๏ธ Development
Local Development
# Clone the actorgit clone https://github.com/apify/people-also-ask-scraper# Install dependenciesnpm install# Run testsnpm test# Run locally with sample inputnode test-local.js
Project Structure
people-also-ask-scraper/โโโ main.js # Main scraper implementationโโโ tests/โ โโโ unit/ # Unit testsโ โโโ integration/ # Integration testsโ โโโ validation/ # Schema validation testsโโโ .actor/โ โโโ INPUT_SCHEMA.json # Input schema definitionโ โโโ Dockerfile # Docker configurationโโโ example-input.json # Sample inputโโโ README.md # This file
๐ Pricing Tiers
Starter
- 100 keywords per run
- Basic PAA extraction
- Dataset output
Pro
- 1,000 keywords per run
- Tree mode expansion
- CSV export + webhooks
Agency
- 10,000 keywords per run
- Priority support
- Custom integrations
๐จ Error Handling
Common Issues
- Blocked by Google: Try reducing concurrency or using different proxies
- No PAA Found: Some keywords don't trigger PAA results
- Rate Limited: Increase delays between requests
Status Codes
- ok: Successfully processed
- blocked: Blocked by Google anti-bot
- no_paa_found: No PAA questions detected
๐ Version History
v1.0.0 (Current)
- โ Initial release
- โ PAA extraction functionality
- โ Tree expansion mode
- โ Multi-locale support
- โ Proxy integration
- โ Multiple output formats
- โ Comprehensive test suite
- โ Error handling improvements
- โ Performance optimizations
๐ License
ISC License - see LICENSE file for details
๐ Support
- Documentation: Apify Documentation
- Issues: GitHub Issues
- Discord: Apify Discord Community
๐ Ready for Production
This actor has been thoroughly tested and is ready for production use:
- โ 30+ passing tests with comprehensive coverage
- โ Robust error handling for edge cases
- โ Performance optimized for large-scale scraping
- โ Schema validated output data
- โ Production ready configuration
The scraper has been validated to handle various scenarios including network issues, rate limiting, and different Google SERP layouts.