Interview Prep
Interview questions, roadmaps and practice sets
Tutorials
Free tutorials on 30+ topics
Blog
Career guides, skills and interview tips
Free PDFs
Notes, cheat sheets and question banks
Certificates
Free skill tests and course certificates
Tools & Whiteboard
Free tools you can use right in the browser
Practice Tests
Mock tests, MCQs and quick Q&A
Free LMS
Learn on the Uncodemy LMS
Choose the best training program according to your career.
Improve the performance of your business with our innovative Industrial Training Program.
Read More →
Our instructor-led training classes are designed to make you an expert.
Read More →
Real-life case studies are a great way to demonstrate your practical knowledge.
Read More →
Explore blogs, latest technologies and industry updates with practical examples.
Read More →Browse all available training programs and choose the right one for your career.
Read More →Know more about who we are and what we stand for.
Discover our mission to equip individuals with essential IT skills and industry expertise.
Read More →
Free tutorials, interview questions, tools and calculators to help you learn.
Explore →Learn, practice and plan your career — bilkul free.
Book a free video counselling session and pick the right course for you.
Read More →Personalisation and privacy are not opposites. The balance comes from three questions you ask before using any customer data: did the person agree to this use, do we need this much data for it, and would they be surprised to see how we used it? If the answers are yes, yes and no, the personalisation is usually both legal and welcome. This guide turns those questions into practical rules for marketing and analytics teams.

Three changes have made "collect everything, decide later" a bad strategy:
Not all personalisation needs the same data. Climb only as high as the business case justifies.
| Level | Example | Data needed | Privacy load |
|---|---|---|---|
| 1. Contextual | Show raincoats to visitors from a city where it is raining today | Current page, approximate location, time; no identity | Very low |
| 2. Session-based | "You viewed these" during the same visit | Activity within one session | Low |
| 3. Declared preferences | Newsletter about the topics a subscriber ticked | What the person told you directly (zero-party data) | Low, with clear consent |
| 4. Behavioural profile | Recommendations based on months of purchases | Purchase and browsing history tied to an account | Medium: needs consent, retention limits |
| 5. Combined or cross-device | Matching app, website and offline store activity to one person | Identifiers across systems, sometimes third-party data | High: needs strong justification and safeguards |
Many teams find that levels 1 to 3 deliver much of the value at a fraction of the risk.
Separate consent for different purposes (order updates, marketing emails, personalised ads) instead of one pre-ticked box. Record when and how each consent was given, and honour withdrawal everywhere, including ad platforms and email tools.
First-party data is what you observe on your own site and app. Zero-party data is what customers tell you on purpose: preferences, sizes, interests. Both are more accurate and easier to justify than bought lists.
For each field, ask "which decision uses this?". If none, do not collect it. A birthday offer needs a day and month, not the full date of birth.
Analysts rarely need names, emails or phone numbers. Replace them with a keyed hash in the analytics layer, and keep the key separately with restricted access.
A report showing "average spend of customers in Nashik" can reveal one person's spending if only one customer lives there. Set a minimum group size and hide values below it.
Delete or aggregate raw event data after a defined period. Old data is a liability in a breach and is rarely useful for personalisation.
A small "Why am I seeing this?" link next to a recommendation, explaining "because you bought running shoes last month", builds trust and gives people a way to opt out.
This Python example pseudonymises emails with an HMAC (a keyed hash), then builds a city report that hides averages for groups smaller than five customers:
import hmac, hashlib
import pandas as pd
SECRET = b"store-this-in-a-secrets-manager"
def pseudonymise(email):
key = email.strip().lower().encode()
return hmac.new(SECRET, key, hashlib.sha256).hexdigest()[:16]
orders = pd.DataFrame({
"email": ["a@x.in", "b@x.in", "c@x.in", "d@x.in", "e@x.in", "f@x.in", "g@x.in", "h@x.in"],
"city": ["Pune", "Pune", "Pune", "Pune", "Pune", "Nagpur", "Nagpur", "Nashik"],
"spend": [1200, 800, 1500, 950, 1100, 700, 1300, 2000],
})
orders["customer_key"] = orders["email"].map(pseudonymise)
orders = orders.drop(columns="email")
report = orders.groupby("city").agg(customers=("customer_key", "nunique"),
avg_spend=("spend", "mean")).reset_index()
MIN_GROUP = 5
report.loc[report["customers"] < MIN_GROUP, "avg_spend"] = None
print(report)
Output:
city customers avg_spend
0 Nagpur 2 NaN
1 Nashik 1 NaN
2 Pune 5 1110.0
Pune has five customers, so its average (5,550 ÷ 5 = 1,110) is shown. Nagpur and Nashik are hidden. Why a keyed hash instead of a plain SHA-256? Email addresses are guessable, so anyone could hash a list of known emails and match them against plain hashes. Without the secret key, HMAC values cannot be matched that way. Pseudonymised data still counts as personal data under most laws, so it needs protection too; it just lowers the risk.
Setting up analytics with these settings is covered in setting up GA4 to track visitor behaviour. If your team is reconsidering its tools, see Google Analytics alternatives, some of which focus on cookieless measurement.
For the personalisation side done responsibly, read AI-personalised email marketing, and for the wider ethics of data use, privacy, bias and responsible AI. This page is general guidance, not legal advice; for a specific product, check the current DPDP rules with a lawyer.