Toolivaro

Calculadora de margem de lucro grátis

Veja a margem de lucro e o markup lado a lado a partir da receita e do custo — com o lucro bruto e o arredondamento sob seu controle.

A calculadora de margem de lucro calcula os três números no centro de quase toda decisão de precificação: o lucro bruto (receita menos custo), o percentual de margem (lucro bruto como parcela da receita) e o percentual de markup (lucro bruto como parcela do custo). Informe quaisquer valores de receita e custo — de um produto, um projeto ou um mês inteiro — e a calculadora mostra os três resultados lado a lado, para que você nunca precise alternar entre fórmulas. Ela segue as convenções padrão: a margem é sempre expressa como percentual da receita, e o markup como percentual do custo; os dois são frequentemente confundidos, por isso a calculadora mostra ambos. O arredondamento é explícito e só se aplica quando os resultados são exibidos, nunca ao cálculo subjacente. Tudo roda localmente no seu navegador — valores de receita e custo nunca saem do seu dispositivo e nunca são registrados. Use esta calculadora ao definir um preço, conferir se uma linha de produto é lucrativa ou comparar margens entre produtos vendidos a preços diferentes.

Processado localmente no seu navegador

Modo de cálculo

Dinheiro total recebido pelas vendas.

Custo direto dos produtos ou serviços vendidos.

Como usar esta calculadora

The three numbers behind every pricing decision

The profit margin calculator answers the question underneath almost every pricing decision: after you sell something, how much of what the customer paid is actually yours? You enter two numbers — the revenue a sale, batch, or project brought in, and the cost of delivering it — and the calculator returns three: gross profit in dollars, margin as a percentage of revenue, and markup as a percentage of cost. The calculator does the subtraction and division in full decimal precision, so the three results always agree with each other to the cent. That last distinction matters more than it looks: margin and markup describe the same profit against two different bases, so the percentages never match except when profit is zero, and mixing them up is one of the most common pricing errors in small business.

Use it before you set a price, not only after the sale. When a supplier offers goods at a lower unit cost, run the numbers with your planned selling price to see how much margin you actually gain. When a product line feels less profitable than it used to, the calculator shows whether the problem sits in your cost or your price. It works for a single item, a batch of t-shirts, or a month of sales — the math is the same at every scale. Keep one limit in mind: this is gross margin, built on the direct cost of the goods sold. Rent, salaries, marketing, and shipping are excluded by design, so the result is a pricing tool, not a full profitability report. If you need the picture after all overhead, that is a net-profit calculation this tool does not attempt.

Entering revenue and cost the right way

Revenue is the total money received from sales before any deductions — the full amount the customer paid, typed in dollars. Enter the number exactly as it appears on your invoice or receipt: the field accepts dots or commas as decimal separators and strips spaces, so 1,250.00, 1.250,00, and 1 250 all parse to the same value. Keep the scale consistent between the two fields — if revenue is the total for a batch, cost must be the total for that same batch, not a per-unit figure. Revenue must be zero or greater, and it must be greater than zero for a margin to exist at all: the calculator refuses to divide by zero and asks you for a usable number instead of inventing one. Zero revenue produces no margin by definition — the calculator explains this instead of showing a division error.

Cost is the direct cost of the goods or services sold: materials, production, and anything you pay per unit to make the sale happen. Leave rent, salaries, marketing, and shipping out of it — those belong in a net-profit figure, and including them turns the margin into something that is neither gross nor net. The most common pitfall is entering net profit into the Cost field, which produces a margin that no longer means anything. Another is entering a percentage as a decimal: a field that expects dollars reads 0.3 as thirty cents, not 30%. And when cost is zero — say you are testing a giveaway — markup is undefined, because dividing profit by zero has no answer; the calculator reports 0.0% markup and a 100.0% margin rather than guessing. If you are unsure whether a cost belongs in the field, ask: would I still pay it if this product sold zero units?

The card also works in reverse. Switch the toggle to "Price for a target margin" and enter your cost plus the margin you want — 30%, say — and the calculator returns the exact selling price that achieves it: cost divided by (1 − 0.30). For a cost of $175, that is $175 ÷ 0.70 = $250.00, which is exactly the t-shirt example above read backwards. Pricing this way keeps the margin decision explicit: you decide the margin, the calculator solves for the price, instead of setting a price first and discovering the margin after the sale. The target must stay below 100% — at 100% the required price is infinite, and above 100% the math breaks down because profit cannot be larger than the price. This is the number to round up from when you set a price tag.

Reading your results: profit, margin, and markup

Gross profit is the simple result: revenue minus cost, shown as a currency amount with two decimals. Margin is that profit as a share of what the customer paid, shown with one decimal place, and it can never exceed 100% — revenue always includes the profit, so profit can never be larger than the revenue it is measured against. Markup is the same profit as a share of what you paid, and it grows well past 100% whenever cost is small: a product that costs $10 and sells for $25 carries a 150% markup but only a 60% margin. Both are shown side by side precisely because they are so often confused — if a number looks implausible, check which base it is relative to before you act on it. Margin is the percentage most retailers quote because it is relative to the price tag; markup is the percentage most manufacturers quote because it is relative to what they spent.

Rounding is display-only. The calculator keeps full decimal precision in every intermediate step and rounds only what you see: currency to two decimals and percentages to one, half away from zero. A margin of exactly 42.8571% displays as 42.9%, but the underlying value stays exact, so re-running the same inputs always returns the same figures. The margin and markup bars cap at 100% and 200% for readability — they are visual guides, not limits on the numbers themselves. Use the results to compare products, suppliers, or price points, because percentages are what make different-sized sales comparable: a 35% margin on a $1,200 project and a 35% margin on a $250 t-shirt batch are different dollars but the same pricing discipline, and that is what you actually manage. You can also verify a supplier's arithmetic: enter their price and cost and see whether the margin they quoted is the one the formula produces.

Como o resultado é calculado?

Precificando um produto: receita de 250, custo de 175

Você vende um lote de camisetas por $250 e ele custa $175 para produzir. Primeiro subtraia o custo da receita: 250 − 175 = 75, então o lucro bruto é $75. A margem divide isso pela receita: 75 / 250 = 0,30, ou 30%. O markup divide pelo custo: 75 / 175 ≈ 0,4286, ou 42,9%. A margem e o markup são números diferentes mesmo com o lucro idêntico — a margem é relativa ao que o cliente paga, o markup é relativo ao que você pagou.

Exemplo de entrada e saída
Entrada Valor
Receita 250.00
Custo 175.00
Resultado Lucro bruto $75.00 · margem 30.0% · markup 42.9%

Pricing a freelance project: revenue 1,200, cost 780

You invoice a client $1,200 for a website design project, and your direct costs — the licensed images, the fonts, and the subcontractor you paid for the animations — come to $780. Subtract cost from revenue first: 1,200 − 780 = 420, so gross profit is $420. Margin divides that profit by the revenue: 420 / 1,200 = 0.35, or 35.0%. Markup divides the same profit by the cost instead: 420 / 780 ≈ 0.5385, or 53.8%. The two percentages measure the same $420 against different bases — margin against the $1,200 the client paid, markup against the $780 you spent. Think of a restaurant tip: a 20% tip feels generous measured against your bill, but it looks enormous measured against what the kitchen spends on ingredients. Here the client's fee is the bill and your direct costs are the ingredients. The 35.0% margin is the number to quote when you plan pricing; the 53.8% markup is the figure a supplier comparing cost structures would recognize. Both come from the same profit, and using one when you mean the other would change your price by roughly $150 on this project. The price you would quote for a 35% markup instead: cost × 1.35 = 780 × 1.35 = $1,053, which is $147 below the $1,200 you actually charged — about the cost of two more hours of work. Notice that the margin and markup tell different stories to different readers: margin is the share of the client's dollar you keep, markup is how many times your cost came back to you. Neither is more correct; they are two lenses on the same profit. Run the same two numbers with different costs to see the sensitivity: if the subcontractor had cost $300 more, profit would be $120 and margin would fall to 10.0% — a thin margin that would make the project barely worth taking.

Exemplo de entrada e saída
Entrada Valor
Receita 1200.00
Custo 780.00
Resultado Gross profit $420.00 · margin 35.0% · markup 53.8%

Selling a digital product: revenue 4,800, cost 1,440

You sell 40 licenses of a small productivity template at $120 each, so revenue is 40 × 120 = $4,800. Your direct costs — the stock photos, a year of demo-site hosting, and the assistant you paid to write the tutorial — come to $1,440. Gross profit is 4,800 − 1,440 = $3,360. Margin is 3,360 / 4,800 = 0.70, or 70.0%. Markup is 3,360 / 1,440 ≈ 2.33, or 233.3% — a markup above 100% is normal for goods with low direct cost. Think of a bakery that sells a croissant for $3 when the flour and butter cost 90 cents: margin shows how much of the sale price you keep, markup shows how many times over you got back what you spent. The template is the same shape with bigger numbers. Compare the 70.0% margin here with the 30.0% margin on the t-shirt batch: the percentages make the two products comparable even though the dollar profits differ wildly, and that comparison is what the calculator is for. Now test the sensitivity: if a licensing fee pushes cost to $2,160 — 45% of revenue — margin falls to 55.0% and markup to 122.2%. You can watch a margin get squeezed before the money lands in your account. The input fields take the same shape as the t-shirt example: revenue and cost as plain dollar amounts. Enter 4800.00 and 1440.00 and the calculator returns gross profit $3,360.00, margin 70.0%, and markup 233.3%. Notice what did not change: the formula is identical to the t-shirt case, only the scale differs — which is exactly the point of a percentage. If you price a second, cheaper template at $30 with $9 of direct cost, the margin is 70.0% again: 30 − 9 = 21, and 21 / 30 = 0.70. Identical margin, a tenth of the price — percentages are the only way to see that the economics are the same.

Exemplo de entrada e saída
Entrada Valor
Receita 4800.00
Custo 1440.00
Resultado Gross profit $3,360.00 · margin 70.0% · markup 233.3%

Qual é a fórmula e suas premissas?

Lucro bruto

gross profit = revenue − cost

Termos da fórmula
Símbolo Significado
revenue dinheiro total recebido pelas vendas antes de qualquer dedução
cost custo direto dos produtos ou serviços vendidos

Percentual de margem

margin % = (revenue − cost) / revenue × 100

Termos da fórmula
Símbolo Significado
revenue − cost lucro bruto
revenue valor total das vendas

A margem é sempre um percentual da receita. Ela nunca pode passar de 100% — o denominador é a receita, que sempre inclui o próprio lucro.

Percentual de markup

markup % = (revenue − cost) / cost × 100

Termos da fórmula
Símbolo Significado
revenue − cost lucro bruto
cost custo direto dos produtos vendidos

O markup é um percentual do custo, então pode passar de 100%. Uma margem de 50% não é o mesmo que um markup de 50% — veja o exemplo resolvido.

Quais são os erros mais comuns?

  • Confundir margem com markup: margem de 30% e markup de 30% são resultados diferentes, e usar um quando você quer dizer o outro desprecifica o produto.
  • Usar lucro líquido em vez de lucro bruto: a margem aqui usa apenas o custo direto, não aluguel, salários ou outras despesas operacionais.
  • Digitar um percentual como decimal (p. ex., 0,3) quando o campo espera um valor em moeda, o que gera resultados errados por um fator de cem.

Quais são as premissas e limitações?

  • A margem bruta exclui custos indiretos como aluguel, salários, marketing e frete — não é um indicador de lucratividade geral.
  • Os resultados são estimativas para decisões de precificação, não aconselhamento financeiro profissional; confirme decisões significativas de preço com dados de custo atualizados e, quando for o caso, com um contador.
  • A calculadora assume um único valor de custo por unidade ou lote; linhas de produto mistas com custos indiretos compartilhados precisam de um modelo mais detalhado.

De onde vêm os números?

Última revisão 12 de agosto de 2026 · Versão 1.1.0 · Toolivaro não garante conteúdo externo.

Perguntas frequentes

Qual é a diferença entre margem e markup?

Margem é o lucro bruto expresso como percentual da receita; markup é o lucro bruto expresso como percentual do custo. Em uma venda de $100 com custo de $60, a margem é 40% enquanto o markup é 66,7%. Eles medem o mesmo lucro sobre bases diferentes, então sempre diferem, a menos que o lucro seja zero.

A margem de lucro pode passar de 100%?

Não. A margem é o lucro dividido pela receita, e o lucro nunca pode superar a receita, então a margem fica sempre abaixo de 100%. O markup, que divide o lucro pelo custo, pode passar de 100% — por exemplo, um produto que custa $10 e é vendido a $25 tem markup de 150%, mas margem de apenas 60%.

Qual é uma boa margem de lucro?

Não existe número universal. Margens brutas típicas variam muito por setor — software e serviços costumam superar 70%, enquanto mercearias ficam entre 20% e 30%. Compare sua margem com seu próprio desempenho passado e com benchmarks publicados do setor, em vez de uma meta arbitrária.

Why is my markup number so much bigger than my margin?

Because the two percentages divide the same profit by different bases. Markup divides profit by cost, and cost is always smaller than revenue for any profitable sale, so markup always comes out larger. On a $100 sale with $60 of cost, profit is $40: margin is 40% and markup is 66.7%. Neither number is wrong — pick the one your audience expects. Retailers usually talk margin because it is relative to the price tag; suppliers and manufacturers often quote markup because it is relative to what they spent. The calculator shows both so you never have to convert.

What happens if I enter zero cost or zero revenue?

Zero revenue is rejected: the calculator asks for revenue greater than zero, because margin divides profit by revenue and dividing by zero has no answer. Zero cost is allowed and handled explicitly: revenue 100 with cost 0 returns gross profit of $100, a 100.0% margin, and a 0.0% markup, because markup divides profit by cost and that division is undefined at zero. Genuine zero-cost sales are rare — most free products still carry hosting, support, or payment-processing costs — so a 100% margin should make you double-check what counts as cost.

Can I use this calculator for a whole month of sales instead of one product?

Yes. Put total revenue for the month in the Revenue field and the direct cost of the goods sold that month in the Cost field — not rent, salaries, or marketing. The result is your gross margin for the period: useful for spotting trends and comparing months, but not net profit, because operating expenses still come out of it. For a clearer read, run one product line at a time, since mixing lines with very different costs blends the percentages and can hide a weak product inside a strong month.

Parte de Calculadoras para negócios de restaurantes

Encontrou um erro ou tem uma correção? Informe — revisamos toda correção.

Foi útil?

Revisado pela equipe editorial da Toolivaro conforme nossa metodologia Metodologia · Política editorial