DAX Measure Generator

Pick the measures you need, type your table and column names, and copy ready-made DAX for Power BI.

🔒 Runs in your browser⚡ Instant results👤 No sign-up⭐ Downloads with Pro

1. Tell us about your data

2. Pick the measures you need

3. Your DAX measures

In Power BI: Modelling → New measure, paste one measure, press Enter. Repeat for each. Create the base measure first, because the others use it.

Correct DAX measures without memorising DAX

Power BI is powerful, but writing DAX for time intelligence and rankings trips everyone up. Type your table and column names once, tick the measures you need and copy ready-made, properly formatted DAX.

Every measure uses best-practice patterns: DIVIDE Instead of "/" to avoid divide-by-zero errors, variables for readability, and correct quoting of table names with spaces.

Tips

Frequently asked questions

Why does my YTD measure show the same as the total?

Time intelligence needs a separate date table that is marked as a date table and joined to your data. Use the date column from the date table in your visuals, not the date column from your sales table.

Do these work in Excel Power Pivot too?

Yes. The same DAX works in Excel Power Pivot (Power Pivot → Measures → New Measure) and in Analysis Services.

Why use DIVIDE instead of the / sign?

DIVIDE returns blank instead of an error when dividing by zero, so your visuals do not show errors.

More data analysis & spreadsheet tools

📊
Excel Data AnalyserInstant KPI dashboard, insights, report & slides
📈
Instant DashboardPower BI style dashboard from any Excel file
🔁
CSV ↔ Excel ConverterConvert CSV, XLSX, XLS, ODS and JSON
🧩
Excel File MergerCombine many spreadsheets into one
🧹
Duplicate RemoverFind and delete duplicate rows
📈
Chart MakerPaste data, get a chart, download PNG or PowerPoint
🗄️
Excel to SQLCREATE TABLE & INSERT statements from any spreadsheet
🧮
SQL Query BuilderBuild SQL with clicks, explained in English, run on your data
✨
SQL FormatterMake messy SQL clean and readable
🧽
Data CleanerFix spaces, capitals, text numbers, dates, blanks and duplicates
🔗
VLOOKUP / Merge Two SheetsMatch two files on a shared column, no formulas
🆚
Compare Two Excel FilesSee added, removed and changed rows and cells
🧊
Pivot Table BuilderGroup, total and chart your data with clicks
🌐
Web Table to ExcelCopy tables from websites into clean Excel
🔣
JSON ↔ Excel ConverterFlatten JSON into a spreadsheet, or Excel into JSON
📍
UK Postcode Lookup (Bulk)Add council, region and lat/long to postcodes
🔄
Unpivot / Reshape DataColumns to rows and back, ready for Power BI
🎯
Outlier FinderSpot unusual values, typos and errors
📐
Statistics CalculatorMean, SD, correlation, t-test, chi-square explained
🎲
Random Sample PickerRandom rows for audits, surveys and prize draws
🧠
DAX Measure GeneratorYTD, YoY %, rank and % of total for Power BI
📅
Date Table GeneratorPower BI / Excel calendar with UK bank holidays
🧩
Excel Formula BuilderXLOOKUP, SUMIFS, IF and more in plain English
⚙️
Power Query SnippetsCopy-paste M code to clean and reshape data
🗄️
SQL PlaygroundRun SQL queries and JOINs on Excel & CSV files
🐘
Large CSV ViewerOpen & filter CSVs with millions of rows
✂️
Split Excel by ColumnOne sheet or file per region, rep or month
🔗
Fuzzy Match (Fuzzy VLOOKUP)Match similar names between two lists
🛡️
Data AnonymiserMask, hash or code personal data for GDPR
📇
Extract Emails, Phones & PostcodesPull contact details out of any text or file
🔮
Forecast & RegressionSales forecast and what drives your numbers
👑
RFM Customer SegmentsFind champions, loyal and at-risk customers
📊
Cohort RetentionHow many customers come back month by month
🅰️
ABC / Pareto AnalysisThe 20% of products that make 80% of sales
⚖️
A/B Test CalculatorIs version B really better? p-value and sample size
🧪
Test Data GeneratorRealistic fake UK data for testing and demos

See all 123 tools →