---
title: "How to Collect Brazil E-Commerce Data: Prices, Pix and CEP"
description: "Check the official API first, then the JSON-LD price. We cover the real format, 12x sem juros installments, CEP-based shipping and what a Brazilian IP changes."
url: https://proxynet.io/blog/brazil-ecommerce-portuguese-data
date: 2026-12-03
author: "Enver Kaya"
category: "Use Cases"
lang: en
---

# How to Collect Brazil E-Commerce Data: Prices, Pix and CEP

Brazil e-commerce data collection means reading the price, installment, shipping and stock fields of Brazilian stores and marketplaces on a schedule and turning them into comparable records. The pages are written in Brazilian Portuguese and use local formats. A price looks like `R$ 1.299,90`, a payment option like `12x sem juros`, and the delivery address is entered as a CEP. The trap is the number format: a parser that treats the dot as a decimal point records `1.299,90` a thousand times too small. In this post we cover the official API, Portuguese search terms, parsing reais and installments, the effect of the CEP and the role of a Brazilian IP.

> **Note: Short answer**
>
> Check the official API first, then the JSON-LD price on the page. In the visible `R$ 1.299,90` text, drop the dots and turn the comma into a dot. Store installments and the Pix price in separate fields, and record shipping and stock against a fixed CEP.

## The official API first

If an official channel exists, you do not need to read pages at all. The Mercado Livre developer documentation defines endpoints for item search and item details. These endpoints require an OAuth access token and are built around a seller account. If you track your own store, a reseller or a partner, start here.

The API returns JSON written for machines. The price arrives as a number, the currency in a separate field. Most of the parsing problems in this post never show up in an API response.

On pages the API does not cover, two rules apply. Follow the site's terms and its robots.txt file. Send requests at a low rate and only as many as you need.

## Portuguese search terms

Brazilian sites are searched in Brazilian Portuguese, not European Portuguese. The same product has a different name in each country. A product searched with the Portugal word returns few results on a Brazilian site or lands in the wrong category.

| Product | Brazil | Portugal |
|---|---|---|
| Mobile phone | `celular` | `telemóvel` |
| Refrigerator | `geladeira` | `frigorífico` |
| Screen | `tela` | `ecrã` |
| Mouse | mouse | rato |

Build your keyword list the way a Brazilian shopper would type it. The suggestions in the search box and the site's own category names are a good starting point.

## Accented characters

Portuguese uses letters such as `ç`, `ã`, `õ`, `á`, `é`, `ê` and `ô` often. In the address bar these letters are percent-encoded as UTF-8 bytes. Python's `quote_plus` turns the query `máquina de lavar` into `m%C3%A1quina+de+lavar`. Do not join the query by hand; use the `params` argument of your HTTP library.

The second problem is Unicode normalization. The word `ação` can be written with precomposed letters or with separate marks, such as `a` plus a combining tilde. In our test both forms looked the same on screen but were not equal in Python: one was 4 characters long, the other 6. Bring the text to one form with `unicodedata.normalize("NFC", text)` before you store it.

Matching needs one more step. Shoppers often skip accents, so `acucar` and `açúcar` search for the same product. Convert the search key to NFD and drop the combining marks to get an accent-free copy. Keep the original text for display. If you see garbled characters, the problem is not normalization but decoding. We cover that diagnosis in our [Python encoding errors](/blog/python-unicode-encoding-errors) post.

## Parsing the real format

In Brazil, thousands are separated by a dot and cents by a comma: `R$ 1.299,90` is one thousand two hundred ninety-nine reais and ninety centavos. The space between the symbol and the number is often a non-breaking space (U+00A0). In Node 24, `Intl.NumberFormat("pt-BR", { style: "currency", currency: "BRL" })` produced this space. A regular expression that looks for a normal space misses the price.

The parsing rule is short. Strip the symbol and the spaces, delete the dots, turn the comma into a dot and store the result as a `Decimal`. Do not use `float`; rounding errors pile up in cent arithmetic.

Check the JSON-LD before the visible text. schema.org recommends a dot as the decimal separator in the `price` field and the currency as an ISO 4217 code in `priceCurrency`. If the JSON-LD shows `"price": "1299.90"` and `"priceCurrency": "BRL"`, there is no format problem.

A page can show two prices together: `de R$ 1.499,90 por R$ 1.299,90`. "De" is the old price, "por" the current one. Write them to separate fields. A script that takes the first match as the price records the old one.

## Installments and the Pix price

Brazilian product pages usually show the price together with installments: `ou 12x de R$ 108,33 sem juros`. "Sem juros" means interest-free, "com juros" means with interest. An installment is a payment option, not a price. Do not write the installment amount into the price field.

The installment amount times the number of installments may not match the price to the cent. On our sample page, 12 × 108.33 came to 1,299.96 while the price was 1,299.90. The gap comes from rounding. If you validate, allow a tolerance of a few centavos.

Pix is the instant payment system of the Central Bank of Brazil. Many stores show a separate price for Pix or upfront payment: `R$ 1.234,90 à vista no Pix`. This is a third value after the current price and the installments. Keep all three in the same record.

| Field | Text on the page | Record |
|---|---|---|
| List price | `de R$ 1.499,90` | `old_price` |
| Current price | `por R$ 1.299,90` | `price` |
| Installments | `12x de R$ 108,33 sem juros` | `installment_count`, `installment_amount`, `interest_free` |
| Upfront price | `R$ 1.234,90 no Pix` | `pix_price` |

Fix which price you compare against competitors. Comparing one store's Pix price with another store's installment price gives a wrong result.

## A script that reads one page

The script below reads a product page through a proxy. It takes the JSON-LD price first, then parses the installments and the Pix price from the visible text.

```python
import json
import re
import sys
from decimal import Decimal

import requests
from bs4 import BeautifulSoup

PROXY = "http://user:pass@pr.proxynet.io:8000"
HEADERS = {"Accept-Language": "pt-BR,pt;q=0.9"}

MONEY = r"R\$\s*(\d{1,3}(?:\.\d{3})*,\d{2})"
INSTALLMENT = re.compile(r"(\d{1,2})\s*x\s*(?:de\s*)?" + MONEY + r"\s*(sem|com)\s+juros", re.I)
PIX = re.compile(MONEY + r"\s*(?:à vista\s*)?no\s+pix", re.I)

def brl(text):
    """'1.299,90' -> Decimal('1299.90')"""
    return Decimal(text.replace(".", "").replace(",", "."))

def jsonld_price(soup):
    for tag in soup.find_all("script", type="application/ld+json"):
        data = json.loads(tag.string or "{}")
        offer = data.get("offers", {}) if isinstance(data, dict) else {}
        if "price" in offer:
            return Decimal(str(offer["price"])), offer.get("priceCurrency")
    return None, None

def fetch(url):
    r = requests.get(url, headers=HEADERS, timeout=20,
                     proxies={"http": PROXY, "https": PROXY})
    r.raise_for_status()
    soup = BeautifulSoup(r.text, "html.parser")
    # turn non-breaking spaces into normal spaces
    text = soup.get_text(" ").replace("\xa0", " ")

    price, currency = jsonld_price(soup)
    result = {"price": price, "currency": currency}
    if m := INSTALLMENT.search(text):
        result["installments"] = (int(m[1]), brl(m[2]), m[3].lower() == "sem")
    if m := PIX.search(text):
        result["pix"] = brl(m[1])
    return result

if __name__ == "__main__":
    print(fetch(sys.argv[1]))
```

On our sample page the output was:

```text
{'price': Decimal('1299.90'), 'currency': 'BRL', 'installments': (12, Decimal('108.33'), True), 'pix': Decimal('1234.90')}
```

The regular expression also caught variants with a capital X and without "de", such as `10X R$ 129,99 com juros`. Sites build this text in different ways. When you move to a new site, test the expression on a few real pages.

## Shipping and stock by CEP

The CEP is Brazil's eight-digit postal code, written as `00000-000`. Product pages show the shipping fee and delivery time only after a CEP is entered. In some stores stock also depends on the region: a product can be on sale in one city and show as `indisponível` in another.

That is why the CEP belongs in the record. Pick a fixed list of CEPs for the regions you track, for example `01001-000` for central São Paulo. Key each record on `(product, CEP, date)`. Shipping data collected without a CEP cannot be compared with data collected under another CEP.

`Frete grátis` can be conditional too. If free shipping depends on an order threshold or a region, write the condition to a separate field. We explain how to read the stock field from JSON-LD in our [product stock monitoring](/blog/marketplace-stock-monitoring) post.

## What a Brazilian IP changes

Stores usually infer a visitor's country from the IP address. A request from outside Brazil can be redirected to an international version, see a different currency or get a "no delivery to your region" notice. The `Accept-Language: pt-BR` header picks the language but does not change the country.

An IP does not replace the CEP. The IP decides which country version the site shows. The CEP decides shipping and stock within that country. Brazilian data needs both.

A [Residential Proxy](https://proxynet.io/residential-proxy) exiting in Brazil lets you fetch the page the way a local visitor sees it. Home connection IPs return the version the store shows to real customers.

Country and city options are on the [Brazil proxy](/locations/brazil) page. Choose Brazil as the target country and check the country of the exit IP on the first request.

Choosing a provider is outside the scope of this post. We made that comparison in our [Brazil proxy providers](/blog/best-brazil-proxy-providers-2026) list.

## Troubleshooting

The problem usually sits in one of these lines, depending on the symptom:

- **Price a thousand times too small.** The dot in `1.299` was read as a decimal point. Do not convert the comma before deleting the dots.
- **Price not found at all.** There is a non-breaking space after the symbol. Replace `\xa0` with a normal space.
- **Old price recorded.** "De" and "por" were not separated. Read the two values separately.
- **Price equals the installment amount.** The installment line was taken as the price. Split installments out with their own regular expression.
- **Same product, two records.** The accented name has two Unicode forms. Normalize with NFC.
- **Inconsistent shipping and stock.** Records were collected with different CEPs. Add the CEP to the key.
- **Page in English or another currency.** The request leaves from outside Brazil. Check the country of the exit IP.

## How we tested

On 3 December 2026 we worked with Python 3.13.17, requests 2.34.2 and Beautiful Soup 4.15.0. The script connected to a local HTTP proxy that logged the incoming request line and headers. For every request the proxy returned a sample Brazilian product page with JSON-LD, a "de/por" price, an installment line and a Pix line. The log showed the `Proxy-Authorization` header and the `pt-BR` language header. We ran the format test with Node 24.22.2 (ICU 78.3) and the normalization test with Python's `unicodedata` module. We did not crawl a real Brazilian store.

## The bottom line

Read the official API first, then the JSON-LD, and parse the visible text last. Store the price, the installments and the Pix price in separate fields, and record shipping and stock together with the CEP. Above all, confirm that the request leaves from Brazil. For ongoing price tracking, see our [price monitoring solution](/price-monitoring).

## Sources

- Mercado Livre developer documentation, Items and searches: [developers.mercadolivre.com.br](https://developers.mercadolivre.com.br/pt_br/itens-e-buscas)
- schema.org, the `price` property: [schema.org](https://schema.org/price)
- Python documentation, the `unicodedata` module: [docs.python.org](https://docs.python.org/3/library/unicodedata.html)
- MDN, `Intl.NumberFormat`: [developer.mozilla.org](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat)

## Frequently asked questions

### How do I convert a Brazilian price to a number in Python?

With `Decimal`. First strip the `R$` symbol and the spaces, then delete the dots that separate thousands, and only then turn the decimal comma into a dot. `1.299,90` becomes `Decimal("1299.90")`. Do not use `float`. The order matters: if you convert the comma first, the number ends up with two dots and the conversion fails.

### What does "12x sem juros" mean?

Twelve equal installments, interest-free. "Com juros" means the installments carry interest. The installment amount is a payment plan, not the product's price. Store the number of installments, the installment amount and the interest flag in separate fields. When you compare prices, use the upfront or list price, not the installment amount.

### Why is the Pix price lower than the product price?

Many stores set a separate price for upfront payment by Pix. Pix is the Central Bank of Brazil's instant payment system, and a store can price it differently from installments. The price appears on the page with a phrase such as "à vista no Pix". Store it in its own field and compare the same price type across competitors.

### Can I see the shipping fee without entering a CEP?

Usually not. The shipping fee and delivery time depend on the region of the address, and the page calculates them only after a CEP is entered. In some stores stock also changes by CEP. For tracking, pick a fixed list of CEPs and write the CEP you used into every record. Otherwise you may mistake a day-to-day difference for a price change.

### Can the Accept-Language header replace a Brazilian IP?

No. `Accept-Language: pt-BR` only states the language you prefer. Stores usually choose the country version, the currency and delivery availability by IP address. A request from outside Brazil may get a Portuguese page and still see a different price or a delivery warning. For accurate results, use the header together with a Brazilian IP.

### Do I need to type accents in Portuguese searches?

It depends on the site. Run the query with and without accents and compare the results. In your own data, keep two copies. For display, normalize the original text with NFC and store it. For matching, convert to NFD and drop the combining marks to build an accent-free key. That way `acucar` and `açúcar` land in the same record.
