VOOZH about

URL: https://apify.com/parseforge/onpe-peru-elections-scraper

⇱ ONPE Peru Elections Results Scraper Β· Apify


πŸ‘ ONPE Peru Elections Results Scraper avatar

ONPE Peru Elections Results Scraper

Pricing

from $7.50 / 1,000 results

Go to Apify Store

ONPE Peru Elections Results Scraper

Pull official ONPE results from the 2021 Peruvian general election by district, province, department, or national level. Returns candidate, party, votes, percentage, valid_votes, blank_votes, and null_votes. Great for political analysis and academic research on Peru.

Pricing

from $7.50 / 1,000 results

Rating

0.0

(0)

Developer

πŸ‘ ParseForge

ParseForge

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

a month ago

Last modified

Share

πŸ‘ ParseForge Banner

πŸ—³οΈ ONPE Peru Elections Results Scraper

πŸš€ Export ONPE Peru 2021 general election results in seconds. District-level vote counts, candidate breakdowns, valid, blank, and null tallies.

πŸ•’ Last updated: 2026-05-29 Β· πŸ“Š 10 fields per record Β· National, Departmental, Provincial, District levels Β· First and second round

The ONPE Peru Elections Results Scraper turns the official resultados.eleccionesgenerales2021.pe JSON reports into a clean, structured dataset. It hits the public ONPE Proceso Electoral endpoints and flattens each candidate's tally into one row per district and party.

Coverage spans every Peruvian department, province, and district reported by ONPE, both presidential rounds, and every registered political organization that appeared on the ballot.

🎯 Target AudienceπŸ’‘ Primary Use Cases
πŸ“Š Political analystsBuild national and regional vote share dashboards
πŸ›οΈ ResearchersStudy turnout, blank vote rates, and null vote patterns
πŸ“° JournalistsVerify district-level outcomes for stories
πŸ€– Data scientistsTrain models on Peruvian electoral data
πŸ—ΊοΈ GIS teamsJoin with shapefiles for choropleth maps
πŸŽ“ StudentsPull primary source data for coursework

πŸ“‹ What the ONPE Peru Elections Scraper does

  • Calls ONPE's public Reportes JSON endpoints for the selected geographic level and round.
  • Flattens each department, province, or district into rows per candidate and party.
  • Surfaces valid, blank, and null vote totals alongside each tally.
  • Casts vote counts and percentages to numbers for clean BI ingestion.
  • Pushes a clean diagnostic record if ONPE returns no results for the requested combo.

πŸ’‘ Why it matters: ONPE's public viewer is a single-page app that hides the underlying JSON behind XHR calls. This actor exposes the raw numbers directly so analysts and journalists can stop scraping screenshots.

🎬 Full Demo

🚧 Coming soon.

βš™οΈ Input

FieldTypeRequiredDescription
levelenumNoNACIONAL, DEPARTAMENTO, PROVINCIA, or DISTRITO. Default DEPARTAMENTO.
roundenumNoP (first round) or S (second round). Default P.
maxItemsintegerNoFree users 10, paid up to 1,000,000.

Example 1 - Department results, first round:

{"level":"DEPARTAMENTO","round":"P","maxItems":100}

Example 2 - District-level second round:

{"level":"DISTRITO","round":"S","maxItems":500}

⚠️ Good to Know: ONPE publishes the 2021 general election results as the definitive archived dataset. Numbers reflect the final ONPE tally and do not change between runs.

πŸ“Š Output

FieldTypeDescription
πŸ—ΊοΈ districtstringDepartment, province, or district name.
πŸ§‘ candidatestringCandidate full name.
πŸ›οΈ partystringPolitical organization.
πŸ—³οΈ votesnumberVotes obtained.
πŸ“Š percentagenumberPercent of valid votes.
βœ… valid_votesnumberTotal valid votes in the geography.
⬜ blank_votesnumberBlank votes total.
🚫 null_votesnumberNull votes total.
πŸ•’ scrapedAtstringWhen this row was fetched.
❌ errorstringSet if the upstream response was an error.

Sample record:

{
"district":"LIMA",
"candidate":"PEDRO CASTILLO TERRONES",
"party":"PERU LIBRE",
"votes":1234567,
"percentage":18.92,
"valid_votes":6512334,
"blank_votes":102345,
"null_votes":87654,
"scrapedAt":"2026-05-29T13:00:00.000Z",
"error":null
}

✨ Why choose this Actor

| πŸ†“ | Works with no API key and no login. | | 🧹 | Flattens ONPE's nested JSON into one row per candidate. | | πŸ”’ | Vote counts and percentages cast to real numbers. | | 🌎 | Covers national, departmental, provincial, and district levels. | | πŸ’Ύ | Push to dataset and export CSV, Excel, JSON, or XML. |

πŸ“ˆ How it compares to alternatives

ApproachSetup timeClean rowsNumeric castingMaintained
Manual download from ONPE site15 min per geography❌❌manual
Browser screenshotshours❌❌manual
This Actor5 sec, no installβœ…βœ…βœ…

πŸš€ How to use

  1. Click Try for free.
  2. Pick level and round.
  3. Click Start. Your dataset is ready within seconds.

πŸ’Ό Business use cases

πŸ“Š Electoral analysis. Build regional vote share dashboards for clients or editorial teams.

πŸ›οΈ Civic research. Quantify blank and null vote rates across departments and provinces.

πŸ“° Newsroom verification. Reporters can cross-check district outcomes in seconds.

πŸ€– Predictive modeling. Use 2021 results as training data for future Peruvian electoral forecasting.

πŸ”Œ Automating ONPE Peru Elections Scraper

  • Make / Zapier: trigger this actor and push results to Airtable or Google Sheets.
  • Cron schedule: native Apify scheduler for periodic refreshes.
  • Webhooks: POST to your endpoint the moment a run finishes.
  • Pipe to BigQuery / Snowflake / Postgres: native Apify integrations.

🌟 Beyond business use cases

πŸŽ“ Education. Teach political science classes with real primary source data.

πŸ§ͺ Personal research. Map your home district's results for fun or curiosity.

🀝 Civic non-profits. Build voter education materials from authoritative numbers.

🧰 Tinkering. Prototype a choropleth visualization using a real-world dataset.

πŸ€– Ask an AI assistant about this scraper

Paste this README into ChatGPT, Claude, or any AI assistant and ask it to map your workflow to the actor's inputs. The schema and field list above contain everything an LLM needs.

❓ Frequently Asked Questions

❓ Do I need an API key? No, ONPE's reports are public.

❓ Which election is covered? The 2021 Peruvian general election, both presidential rounds.

❓ Can I get district-level data? Yes, set level to DISTRITO.

❓ Are vote counts cast to numbers? Yes.

❓ Does the data change? No, ONPE has published final tallies for 2021.

❓ Can I schedule runs? Yes via the Apify scheduler.

❓ Is this scraping or API? Public JSON endpoints from the ONPE viewer.

❓ What format can I download? CSV, Excel, JSON, JSONL, XML, RSS, or HTML.

❓ What if ONPE returns nothing? A single diagnostic record with the error field populated is pushed.

❓ Will the schema change? Stable.

πŸ”Œ Integrate with any app

Apify ships native integrations with Make, Zapier, Slack, Discord, Google Drive, Google Sheets, Gmail, Airbyte, Keboola, Telegram, GitHub, and any REST API or webhook. Trigger runs from a calendar event, a form submission, a cron job, or pipe results straight into BigQuery, Snowflake, or Postgres.

πŸ”— Recommended Actors

ActorWhat it does
ParseForge Alpha Vantage ScraperPublic market data.
ParseForge OurAirports ScraperGlobal airport database.
ParseForge collection900+ production scrapers.

πŸ’‘ Pro Tip: browse the complete ParseForge collection for 900+ production-grade scrapers across business intelligence, real estate, e-commerce, sports, finance, and public records.


Disclaimer: This actor scrapes only publicly available data. ParseForge is not affiliated with, endorsed by, or sponsored by any of the third-party services referenced. Users are responsible for complying with the target site's terms of service and applicable law. Create a free account w/ $5 credit.

You might also like

Urbania Peru Property Listings Scraper

scrapers_lat/urbania-scraper

Scrape Urbania property listings in Peru. Extract price, currency, operation, property type, bedrooms, bathrooms, area, district, images, publisher and coordinates from sale and rent listings.

3

5.0

Political Donations Search

hanamira/political-donations-search

Search FEC campaign finance data. Find political donations by donor name or employer. Look up candidate fundraising and PAC finances. Filter by state and election cycle (2016-2024). Official public records from the Federal Election Commission. Track money in politics.

CONADIS Peru Disability Registry Scraper

parseforge/conadis-peru-disability-registry-scraper

Parse CONADIS Peru observatory tables for disability statistics by region, returning region, year, disability_type, count, age_group, and gender. Useful for accessibility research, social policy analysis, NGO planning, and demographic studies across Peruvian departments and age groups.

Adondevivir Peru Property Listings Scraper

scrapers_lat/adondevivir-scraper

Scrape Adondevivir property listings in Peru. Extract price, currency, operation, property type, bedrooms, bathrooms, area, location, images, agent and coordinates.

2

5.0

SCE/SEACE Peru Procurement Scraper

scrapers_lat/seace-scraper

Extract Peru SEACE public procurement future-contracting announcements: entity, dates, type, object and description.

2

5.0

Peru SUNAT RUC Scraper | Business Registry Lookup

parseforge/peru-sunat-ruc-scraper

Extract Peruvian business registry data from SUNAT by RUC: legal name, address, status, taxpayer type, activity, and registration date. Filter by RUC list. Built for B2B lead generation, compliance, KYC, and verifying Peruvian companies and tax records.

US Election Data Scraper

crawlerbros/us-election-data-scraper

Search US elections, candidates, and ballot measures via the Wikipedia MediaWiki API - free, no auth or proxy required.

Urbania Scraper β€” Peru Property Data & API

sian.agency/urbania-property-scraper

Urbania scraper & real estate data API for one of Peru's biggest property portals (Navent). Sale & rent listings: price in soles + USD, area, rooms, baths, parking, address, GPS, photos, advertiser WhatsApp β€” clean JSON/CSV. Overview or detail. No API key needed.

5

SUNAT Peru RUC Scraper

scrapers_lat/sunat-scraper

Extract Peru SUNAT taxpayer records by RUC or company name: legal name, status, tax address, CIIU activity, legal representatives and every branch location (establecimientos anexos) with code, type and address.

2

5.0

FEC Federal Candidate Finance Scraper β€” Receipts & Cash

compute-edge/fec-candidates-finance-scraper

Extract every federal candidate's campaign finance totals from the FEC β€” receipts, disbursements, cash on hand, debts, individual itemized contributions, party committee transfers. Filter by cycle, office, state, party, candidate status.