
The Lei Geral de Proteção de Dados Pessoais (LGPD)—Brazil’s General Data Protection Law—came into effect in 2020. Much like Europe’s GDPR, it gives people more control over their personal data and sets out clear rules for how companies can collect, store, and use it.
But LGPD isn’t just a copy of GDPR. It reflects Brazil’s legal and cultural context, enforced by the Autoridade Nacional de Proteção de Dados (ANPD). For companies operating in or serving users from Brazil, LGPD compliance isn’t just a checkbox—it’s a matter of trust and legal risk.
And when it comes to data protection, the database is where it all becomes real. This is where personal data lives, where access happens, and where things can go wrong if not managed carefully.
In this post, we’ll look at LGPD through a database lens—and show how Bytebase helps teams bake compliance into their day-to-day workflow.
Who LGPD Applies To
LGPD applies to any organization—Brazilian or foreign—that processes personal data from individuals located in Brazil.
It defines:
- Personal data as any information that can identify someone, directly or indirectly.
- Sensitive data as information about health, biometrics, religion, political beliefs, or ethnicity.
So if your systems store or process user data from Brazil—even if your servers sit halfway across the world—you fall under LGPD. And because the database holds the most sensitive data, it’s the first place you need strong controls.
Under LGPD, the same three roles from GDPR apply:
- The Data Subject (Titular) is the individual whose personal data is collected.
- The Controller (Controlador) decides how and why data is processed.
- The Processor (Operador) handles data on behalf of the controller.
Both must designate a Data Protection Officer (Encarregado) as the contact point with Brazil’s ANPD and data subjects.
LGPD Principles Meet Database Reality
Article 6 of LGPD lists ten principles for handling personal data. Many of them map directly to how databases should be managed.
LGPD Principle | What It Means for Databases | How Bytebase Helps |
---|---|---|
Purpose – Use data only for legitimate, specific reasons | Every schema or data change should have a clear purpose | Issue-based workflow tracks who changed what, and why |
Security – Prevent unauthorized access | Control who can access which databases | RBAC and approval policies enforce least privilege |
Accountability – Prove you’re following the rules | Show evidence of controls | Review workflow and immutable audit log provide an auditable trail |
Necessity – Limit processing to what’s essential | Avoid querying or exposing extra data | Dynamic data masking hides sensitive fields in query results |
Instead of leaving these principles to policy documents, Bytebase brings them into your database workflow.
Processing Data on a Legal Basis
LGPD says you can only process personal data if there’s a valid reason—such as user consent, legal obligation, or legitimate interest.
In practice, that means you need to know why each piece of data exists and be able to remove it when that reason no longer applies.
Bytebase makes this easier with issue-based workflow and audit log, so every change is reviewed, recorded, and tied to a legitimate purpose. If you ever need to prove compliance, you already have the evidence.
Handling Sensitive and Anonymized Data
Sensitive data—health, biometric, or belief-related information—gets special protection under Article 11. At the same time, LGPD encourages anonymization whenever possible.
Here’s how Bytebase helps with both:
- Access control (RBAC) limits who can see or modify sensitive tables.
- Dynamic masking hides real values in query results, perfect for lower environments.
- Review worfklow ensures all schema and permission changes are peer-reviewed before rollout.
It’s how you turn “we should protect sensitive data” into “we actually do.”
Honoring Data Subject Rights
LGPD gives individuals rights to access, correct, delete, and even port their data. That sounds straightforward—until you realize it often involves multiple databases and dozens of tables.
Bytebase helps you act responsibly without chaos:
- The database catalog gives you visibility into where personal data lives.
- The SQL Editor lets you run controlled operations—like a targeted deletion—under proper review and audit.
So when users exercise their rights, you can respond accurately and securely.
Being Ready for Incidents
If a security incident exposes personal data, LGPD requires companies to notify both the ANPD and the affected users. That’s not the time to start figuring out who had access or what changed.
Bytebase helps you prepare:
- Every SQL execution is logged and attributed.
- Environment segregation keeps production data isolated from test or staging.
- Immutable records support clear post-incident investigation.
With those in place, you’re not just reacting—you’re ready.
Proving and Maintaining Compliance
LGPD’s final principle is accountability: it’s not enough to comply—you have to prove it.
With Bytebase, every schema update, permission change, and data fix goes through an approval workflow. All of it is traceable, reviewable, and exportable for audits. And because policies are enforced consistently across environments, compliance isn’t a one-off effort—it’s continuous.
Closing Thoughts
Compliance with LGPD starts where your data lives. By embedding review, access control, and auditability directly into your database development process, Bytebase helps teams turn complex legal requirements into everyday best practices.
In short: LGPD compliance isn’t a separate project—it’s how you work. And Bytebase makes that possible.