A checkbox is a moment. An audit trail is the evidence you may need later. Learn how to record consent clearly, keep it distinct from product state and attach action-specific agreements to the action itself.

A consent checkbox is not the record. When a customer, support colleague or regulator later asks what was agreed, the useful answer is evidence: the version shown, when the person agreed and how the event was tied to their account or action.
This article is a product-engineering guide, not legal advice. Work with your privacy adviser on your lawful basis and retention obligations. In the UK, the ICO says organisations should keep evidence of consent for as long as they rely on it to demonstrate compliance.
The ICO’s guidance on recording consent recommends keeping records of who consented, when, what they were told, how they consented and whether they withdrew it. This is a useful engineering specification as well as a compliance prompt.
UK GDPR Article 7 places conditions on consent and requires the controller to be able to demonstrate that consent was given. Read the legislation’s Article 7 text with your adviser rather than treating a database schema as a legal conclusion.
A profile field called consented can look convenient until it has to mean several things: accepted terms, finished onboarding, opted into marketing or passed an account review. Those meanings should not share one boolean. A user who consented and then abandoned setup is not the same as a user who never saw the terms.
Create a consent record at the moment of the agreement and retain product state separately. That makes support questions and data exports answerable without inferring history from a current account flag.
An account-level acceptance may need a first-agreement record that cannot be silently overwritten. A consent prompt for a high-risk action, such as transferring ownership or deleting data, may instead need the latest confirmed agreement immediately before that action. These are different models. Choose deliberately rather than allowing an upsert to make the decision by accident.
Where there is an event log, it can hold the complete sequence. A current consent table can then hold the latest applicable state. The important thing is that a reviewer can distinguish an updated state from erased history.
The most serious agreement is often not general account terms. It may be the confirmation before deleting data, transferring ownership or starting a paid commitment. Record that consent for the precise action, and write it in the same database transaction as the action where possible.
If the action rolls back, its consent record should roll back too. If the system writes the consent first and the action fails, it has manufactured misleading evidence. The receipt should describe an event that actually occurred.
Do not place compliance evidence in a field the subject can freely change. Restrict writes to controlled server functions or database procedures, and make direct client access unavailable unless there is a clear, reviewed reason. Log the write without copying secrets or unnecessary personal data into logs.
Before introducing a new enforcement rule, measure existing records. Check who would be blocked, whether older accounts need a respectful remediation path and whether the migration preserves the original event dates. The goal is to add a real guardrail, not surprise valid customers with a dead end.
Good consent recording is not a legal flourish added after the feature. It is a small, well-defined system that lets the business explain what happened with confidence. That is useful to people using the product, too: important choices become clearer when the product treats them as important.
Usually not by itself. A useful record also identifies the person, the purpose or action, what was shown and how the agreement was captured.
The subject needs meaningful ways to withdraw or change relevant choices, but the historical evidence should be controlled so it cannot be silently rewritten.
No. When the consent specifically confirms that action, write it atomically with the action so a failed transaction leaves no misleading record.
Ready when you are