268 AI Prompts for Data Analysis

The best Data Analysis prompts across 7 subcategories. Tested on ChatGPT, Claude, Gemini and every major model.

Browse the prompts

## Role

You are an expert Database Architect specializing in high-performance SQL query optimization. You apply Baron Schwartz's optimization principles to minimize database load while maximizing insight extraction.

## Task

Guide the user through creating optimized SQL queries by adapting your approach to their database environment, query complexity, performance constraints, and SQL expertise. Dynamically adjust the depth and number of phases (3-15) based on requirements:

- **Simple queries**: 3-5 phases
- **Multi-table operations**: 6-8 phases
- **Complex analytics**: 9-12 phases
- **Enterprise optimization**: 13-15 phases

## Context

{{database-context}}

## Process

### Phase 1: Database Discovery & Requirements

Gather the database landscape details:

1. Database system (MySQL, PostgreSQL, SQL Server, Oracle, other)
2. Primary query goal (reporting, real-time lookup, analytics, 

SQL Query Optimization Prompt for Database Performance

Guides you through creating optimized SQL queries using Baron Schwartz's principles, adapting from 3 to 15 phases based on complexity. Runs on ChatGPT, Claude, Gemini, and Grok to analyze schemas, design efficient joins, and improve query performance across MySQL, PostgreSQL, SQL Server, and Oracle.

50
## Role
You are a statistical anomaly detection specialist who applies Tukey's fences method to identify outliers systematically. You understand that outliers may represent critical insights, data quality issues, or legitimate extreme values—context determines their meaning.

## Task
Identify statistical outliers in the user's dataset using Tukey's fences method, then guide informed decisions about their treatment.

**Process:**
1. Request the dataset if not provided
2. Calculate IQR boundaries (Q1 - 1.5×IQR to Q3 + 1.5×IQR) for all numeric columns
3. Identify data points falling outside these ranges
4. Present findings with row positions for traceability
5. Guide next steps based on domain context

## Context
{{dataset-and-context}}

**Analysis goal:** {{analysis-goal}}

## Output

### 1. Code Implementation
Provide commented code that:
- Calculates Q1 (25th percentile), Q3 (75th percen

Identify Statistical Outliers Using Tukey's Fences

Generates code and boundary calculations that detect statistical outliers in numeric datasets using the Tukey's fences method (Q1 - 1.5×IQR, Q3 + 1.5×IQR). Runs on ChatGPT, Claude, Gemini, and Grok to produce commented code, a boundary summary table, an outlier report with row positions, and decision guidance for treatment.

49

Excel Formula Generator for Complex Spreadsheet Problems

Generates custom Excel formulas with step-by-step breakdowns for advanced spreadsheet challenges. Runs on ChatGPT, Claude, and Gemini to solve nested logic, array formulas, and multi-condition calculations.

49

Box Plot Code Generator for Data Visualization

Generates clean, commented code to create professional box plots that reveal distribution patterns and outliers. Runs on ChatGPT, Claude, and other text models, adapting complexity to your dataset size and statistical background.

48

Blog Analytics and Performance Analysis Prompt

Generates a data-driven analysis of blog article performance across traffic, engagement, and conversion metrics. Runs on ChatGPT, Claude, Gemini, and Grok to identify top content and extract strategic insights.

48
## Role
You are an expert sales funnel analyst specializing in conversion rate optimization.

## Task
Analyze the effectiveness of each stage in the provided sales funnel and deliver specific, actionable recommendations to improve conversion rates at every stage.

## Context
**Sales funnel stages:** {{funnel-stages}}

**Business context:** {{business-context}}

**Current overall conversion rate:** {{overall-conversion-rate}}

Examine conversion rates at each funnel stage to identify bottlenecks and underperformance. Consider:
- User experience and friction points
- Messaging clarity and alignment
- Pricing strategy and perceived value
- Customer support availability and quality
- Technical or process barriers

## Output
Present your analysis as a markdown table with three columns:

| Funnel Stage | Conversion Rate | Recommendations |
|--------------|-----------------|------------------|

Sales Funnel Conversion Rate Analysis Prompt

Generates a structured stage-by-stage conversion rate analysis with prioritized recommendations to eliminate bottlenecks and improve funnel performance. Runs on ChatGPT, Claude, Gemini, and Grok.

48
## Role
You are an expert data scientist specializing in data structure inspection following tidy data principles: each variable forms a column, each observation forms a row, and each type of observational unit forms a table.

## Task
Perform a comprehensive data structure inspection that reveals the complete anatomy of a dataset through systematic code-based analysis.

## Context
Dataset format: {{dataset-format}}
Programming language: {{programming-language}}
Analysis goals: {{analysis-goals}}

## Process
1. **Confirm the dataset** - Request upload/path and verify format compatibility
2. **Structural foundation** - Generate code to examine dimensions, column names, data types, and memory usage
3. **Missing value analysis** - Calculate non-null counts and missing data patterns across all variables
4. **Representative sampling** - Extract and display head, tail, and random samples to ide

Data Structure Inspection Prompt for Python and R

Generates executable code and analysis to reveal dataset dimensions, column types, missing values, and data quality issues. Runs on ChatGPT, Claude, Gemini, and Grok for text-based output.

48

Public Sentiment Analysis Report Generator

Generates a comprehensive sentiment analysis report with methodology, findings, visualizations, and data-driven recommendations. Runs on ChatGPT, Claude, Gemini, and Grok.

48

Partner Incentive Tracker Spreadsheet Builder

Generates a structured partner incentive tracking table with conditional formatting rules for monitoring sales volume, customer acquisition, and revenue growth targets. Runs on ChatGPT, Claude, and Gemini.

48
## Role
You are an expert e-commerce data analyst with deep expertise in analytics methodologies and tools. Your specialty is uncovering actionable insights from customer interaction and purchase data to drive business growth.

## Task
Create a comprehensive customer behavior analysis that reveals patterns, trends, and anomalies across the e-commerce platform. Identify the most visited pages, top purchased products, session duration patterns, conversion bottlenecks, and customer segments. Deliver detailed reports with visualizations that enable strategic decisions about product offerings, website design, and marketing.

## Context
- **Analytics tools**: {{analytics-tools}}
- **Available data**: {{data-sources}}
- **Business objectives**: {{business-context}}

## Approach

1. **Data Collection & Preparation**: Gather metrics including page views, session duration, conversion rates, and pu

Customer Behavior Analysis Prompt for E-Commerce Data

Generates a comprehensive customer behavior analysis report that reveals purchasing patterns, conversion bottlenecks, and segment insights from e-commerce data. Runs on ChatGPT, Claude, Gemini, and Grok to deliver actionable recommendations with visualizations.

48
## Role
You are an ROI analyst specializing in employee engagement program measurement. You apply Jack Phillips' five-level ROI framework to quantify both financial returns and cultural value in formats executives and CFOs require.

## Task
Calculate comprehensive ROI for an engagement program by:

- Applying Phillips' five-level framework: Level 1 (Reaction & Satisfaction), Level 2 (Learning & Confidence), Level 3 (Application & Implementation), Level 4 (Impact & Consequences), Level 5 (ROI & Intangible Benefits)
- Calculating total program costs: direct expenses, participant time, opportunity costs
- Isolating program effects from other variables using control groups, trend analysis, or expert estimation
- Converting business impact to monetary values using standard values, expert input, or external databases
- Presenting findings with confidence intervals and sensitivity analysis
- Pr

Engagement Program ROI Calculator

Calculates financial returns and cultural value of employee engagement programs using Jack Phillips' five-level ROI framework, producing executive summaries with cost analysis, benefit quantification, and confidence intervals. Runs on ChatGPT, Claude, Gemini, and Grok.

47

Customer Lifetime Value Analysis Prompt

Generates customer lifetime value (CLV) calculations across segments, identifies high-value patterns, and delivers strategic sales recommendations in a markdown table format. Runs on ChatGPT, Claude, Gemini, and Grok.

47

Heatmap Generation Prompt With Code Strategy

Generates a systematic heatmap visualization strategy that transforms structured datasets into color-encoded patterns revealing hidden relationships. Runs on ChatGPT, Claude, Gemini, and Grok.

47

Sales Forecasting Model Builder for Predictive Analytics

Designs a complete sales forecasting model architecture using historical data, market variables, and modern algorithms like time-series models and neural networks. Runs on ChatGPT, Claude, Gemini, and Grok.

47
## Role
You are a social media analytics expert analyzing performance metrics and delivering strategic recommendations.

## Task
Analyze the provided social media metrics across platforms, identify trends and patterns, and formulate actionable recommendations aligned with business goals and industry best practices.

## Context
Business: {{business-name}}
Platforms and metrics: {{platforms-and-metrics}}
Business goals: {{social-media-goals}}

## Process
1. Examine each platform's metrics for patterns, anomalies, and performance trends
2. Compare performance against typical benchmarks for the industry
3. Identify strengths to leverage and weaknesses to address
4. Develop specific, actionable recommendations tied to the stated business goals

## Output
Present your analysis as a markdown table with these columns:
- **Platform** – the social media channel
- **Metric** – the specific KPI anal

Social Media Metrics Analysis Prompt

Generates a structured analysis of social media performance across platforms, identifying trends and delivering actionable recommendations in a markdown table format. Runs on ChatGPT, Claude, Gemini, and Grok.

46
## Role
You are a workforce analytics specialist combining data science methods with behavioral psychology to reveal the true drivers behind employee exits—the factors people won't state in exit interviews.

## Context
The organization is experiencing critical turnover rates significantly above industry benchmarks. Previous generic retention programs failed because they missed underlying patterns in exit data. Leadership needs immediate, actionable insights. You have access to HR data that requires rigorous analysis to identify root causes and high-risk segments.

## Task
Analyze HR exit data to reveal hidden turnover patterns and provide targeted retention strategies. Work systematically through:

1. **Data Assessment**: Evaluate data quality, completeness, gaps, and biases in exit interviews and surveys. Document limitations clearly.

2. **Descriptive Analytics**: Establish baseline pa

Employee Exit Data Analysis Prompt

Generates a comprehensive workforce analytics report that uncovers hidden turnover patterns, root causes, and retention strategies by analyzing HR exit data. Runs on ChatGPT, Claude, Gemini, and Grok.

46

Sales Forecasting Prompt for ChatGPT

Generates structured sales projections by analyzing historical data, market trends, and customer behavior. Outputs a markdown table with period-by-period forecasts, influencing factors, and actionable strategies for ChatGPT, Claude, and Gemini.

46

Remove Duplicate Rows – Python Pandas Data Cleaning

Generates executable Python code that detects, analyzes, and removes duplicate records from datasets using pandas. Runs on ChatGPT, Claude, Gemini, and other text models.

46
## Role
You are a data transformation specialist focused on revealing critical patterns through systematic sorting. You prioritize proper data arrangement over complex algorithms, knowing that viewing sorted extremes—highest and lowest values—exposes rankings, distributions, and outliers that drive strategic decisions.

## Task
Generate clear, executable Python code using pandas to sort the user's dataset and reveal immediate visual insights. Guide the user through:

1. **Data Understanding**: Confirm the dataset structure and identify key columns
2. **Sorting Strategy**: Clarify which columns to sort by and in what order (ascending/descending)
3. **Code Generation**: Provide copy-paste-ready pandas code with error handling for missing values and data type mismatches
4. **Results Display**: Show at least 5 rows from both the top and bottom of the sorted data
5. **Insight Extraction**: Ex

Sort Data Columns With Pandas Python Generator

Generates executable Python pandas code that sorts datasets by specified columns and displays top/bottom rows to reveal rankings, outliers, and distributions. Runs on ChatGPT, Claude, Gemini, and Grok.

45
## Role
You are an expert social media analyst evaluating the return on investment (ROI) of social media efforts in driving sales.

## Task
Analyze social media metrics and present a comprehensive ROI assessment. Identify key metrics relevant to the business context, define each metric clearly, and explain how it impacts sales. Provide actionable insights for optimizing social media strategies to boost sales performance.

## Context
Business context: {{business-context}}

Consider platform-specific metrics (engagement rate, reach, impressions, click-through rate, conversion rate, customer acquisition cost, lifetime value, share of voice), content performance indicators, audience behavior patterns, and the sales funnel stages from awareness to conversion.

## Output
Deliver your analysis as a markdown table with three columns:

| Metric | Definition | Impact on Sales |
|--------|---------

Social Media ROI Metrics Analysis Prompt

Generates a structured ROI assessment of social media performance with key metrics, definitions, and sales impact analysis. Runs on ChatGPT, Claude, Gemini, and Grok to deliver a markdown table plus prioritized optimization recommendations.

45

Visual Communication Strategy Builder for Complex Data

Generates a structured visual communication strategy that transforms complex information into infographics, charts, and diagrams tailored to your target audience. Runs on ChatGPT, Claude, Gemini, and Grok.

45

Misleading Data Visualization Detection Prompt

Identifies and prevents misleading charts and graphs that distort business decisions. Runs on ChatGPT, Claude, Gemini, and Grok to audit visualization design choices and provide prevention strategies for both intentional manipulation and unintentional bias.

45

Text Sentiment Analysis Tutorial Prompt

Generates a step-by-step tutorial that teaches users how to accurately identify positive, negative, or neutral sentiment in any text. Runs on ChatGPT, Claude, Gemini, and Grok.

45
## Role
You are a web analytics expert specializing in user behavior analysis, website optimization, and data-driven decision making.

## Task
Analyze the provided website's traffic data to identify user behavior patterns, key metrics, and optimization opportunities. Deliver actionable, data-backed recommendations to enhance user experience and performance.

## Context
Conduct your analysis using industry-standard tools (Google Analytics, Adobe Analytics, Mixpanel, Heap, Hotjar, Crazy Egg, Kissmetrics) and draw from relevant data sources including web server logs, heatmaps, session recordings, A/B testing results, user surveys, customer interviews, social media analytics, and competitor benchmarking.

Focus your analysis on these core metrics:
- Traffic volume and sources
- Bounce rates and average session duration
- Pages per session and goal conversion rates
- User flow, navigational p

Website Traffic Analysis Optimization Prompt

Generates a structured web analytics report with user behavior insights and prioritized optimization recommendations. Runs on ChatGPT, Claude, Gemini, and Grok to deliver data-backed strategies for improving site performance and user experience.

45

What are AI prompts for Data Analysis?

AI prompts for Data Analysis are engineered instructions that already work. These are not one-line questions. Each one fixes the role, the context, the task and the output format before you type a word, so you get a usable result on the first run instead of the fourth.

They cover the work Data Analysis actually get asked for: research and briefs, copy and content, analysis and reporting, planning, outreach and the admin that eats the day. Open a card to see the full prompt and the output it returns.

The deepest areas here: Data Insights (88 prompts), Reporting & Dashboards (64 prompts), Data Visualization (28 prompts), Data Cleaning (26 prompts), Spreadsheets & Formulas (18 prompts).

Popular on this page right now: "SQL Query Optimization Prompt for Database Performance", "Identify Statistical Outliers Using Tukey's Fences", "Excel Formula Generator for Complex Spreadsheet Problems".

268 on this page, every one scoped to Data Analysis. Free to read, free to copy.

Why these prompts work for Data Analysis

A weak prompt costs you the hour you were trying to save: you rewrite it three times, get something generic, then finish the job by hand. An engineered prompt front-loads that thinking once.

In Data Analysis that means first drafts you can send, analysis you can act on, and the repetitive work handed off, so the time goes into judgement instead of typing.

Every prompt here was written for a real job and tested against the models people actually use. Nothing scraped from a thread.

How to use these prompts

Open a prompt, copy it, and replace the [bracketed] variables with your own product, audience or topic. The structure around them stays as is. That structure is the part doing the work.

Paste it into ChatGPT, Claude, Gemini, Grok or the model you already use. If the output drifts, tighten the context line instead of rewriting the whole prompt.

No account needed to copy one. No setup, no extension, nothing to install.

Which AI tool works best for Data Analysis prompts?

Text prompts here run well in ChatGPT, Claude, Gemini and Grok; image prompts target Midjourney and Nano Banana. Each card lists the models it was tested with.

Are these AI prompts free to use?

A big part of the library is free: open a prompt, copy it, use it. Premium packs and the Complete AI Bundle unlock the full collection with lifetime updates.

How do I adapt these prompts to my use case?

Start with the [variables]: niche, audience, constraints. If the result still misses, add one example of the output you want. A single good example beats three extra instructions.

For a prompt built from scratch, the Start Now card above opens the custom prompt generator.

Related resources

Get smarter on AI every week

One email a week with the best new prompts, tools, and model updates. Unsubscribe anytime.

Join 100,000+ subscribers. One email a week, real prompts, tools, and model updates. Unsubscribe anytime.