Yes, you can make a Gantt-style PivotChart in Excel by plotting task start dates and durations as a stacked bar chart, then hiding the start-date series. Excel does not have a dedicated Gantt chart type, however, and a regular stacked bar chart is often easier to set up and maintain.
Can a PivotChart work as a Gantt chart?
A Gantt chart displays tasks as horizontal bars positioned along a calendar timeline: each bar begins on its task’s start date and extends for the task’s duration. Excel’s built-in chart list does not include a Gantt chart, but a stacked bar chart can imitate one. Its first series positions each bar at the correct start date; its second series draws the visible duration.
A PivotChart can use that same basic construction when its PivotTable supplies one start value and one duration value for each task. The advantage is interactivity: PivotTable fields can let you filter the schedule by project, team, phase, or another category. The trade-off is extra setup and some PivotChart behavior that can be less flexible than a normal chart. A PivotChart is therefore an option, not a special Gantt feature.
For a small schedule that rarely changes, a normal stacked bar chart is usually the simplest route. For a schedule people need to filter repeatedly, a PivotChart can be useful if the source data is arranged carefully.
Prepare task data for the chart
Keep the source as a flat table with one row per task and a header in every column. A practical layout is:
- Task: a clear task name, such as Draft design or Review prototype.
- Start: a real Excel date, not a date-looking text string.
- Finish: the planned end date.
- Duration: the number of days represented by the bar.
- Project, Phase, or Owner: optional fields that can be used to filter or group the schedule.
For example, a design task might start March 2, 2026, and finish March 6, 2026. With start dates in B2 and finish dates in C2, enter this in D2 to calculate elapsed days: =C2-B2. The result is 4 days. This treats the finish date as the point when the elapsed period ends; if your schedule counts both the first and last calendar dates as full workdays, use =C2-B2+1 instead, which returns 5 for those example dates. Choose one convention and apply it consistently.
Format the source range as an Excel table with Insert > Table, and confirm that the table has headers. Tables can expand as tasks are added, which makes the source easier to maintain. If task names are repeated, add a unique task ID or use a label that distinguishes each task; otherwise, a PivotTable may combine identically named tasks into one item.
Build the PivotTable summary
Click a cell in the source table and choose Insert > PivotTable. Confirm the table or range and select where the PivotTable should go. In the PivotTable Fields pane, arrange the fields like this:
- Drag Task (or a unique task label) to Rows.
- Drag Start to Values and set it to summarize by Min.
- Drag Duration to Values and set it to summarize by Sum.
- Optionally drag fields such as Project or Phase to Filters, or add them as slicers later.
To change a value calculation, open the field’s menu in the Values area, choose Value Field Settings, and select the appropriate summary. Min is suitable for a task’s start date when there is one source row per task. Sum is suitable for duration in that same one-row-per-task setup. If the source includes several records for a task, those calculations may no longer represent the schedule correctly: a summed duration can overstate the task length, while the minimum start may conceal separate work periods. In that case, decide how each task should be represented before building the chart.
Check that the PivotTable displays one row per intended chart bar and that the start values are dates. Remove grand totals and subtotals if Excel adds them; totals are not tasks and can become misleading bars. If a task needs several separate periods, model those periods as separate task segments rather than assuming one continuous bar can show gaps.
Insert and format the PivotChart
Click inside the PivotTable, then choose PivotTable Analyze > PivotChart. In the chart selection window, choose Bar and then Stacked Bar. Avoid 100% Stacked Bar: that chart scales each task to a percentage of a total, which does not represent a calendar schedule. The resulting chart should contain two series, usually the start value and the duration.
Format the Start series so it is invisible. Select one of its bars, open Format Data Series, and set Fill to No fill and Border to No line. This series still takes up space on the value axis, pushing the duration bar to its start position, but it no longer appears as a colored bar. Give the Duration series a readable fill color. If Excel selects the whole chart instead of a series, click a bar again or use the chart’s selection controls to choose the intended series.
The task names may appear in an inconvenient order because bar charts commonly place the first category at the bottom. Select the vertical category axis, open Format Axis, and enable Categories in reverse order if that arrangement better matches your schedule. You can also adjust the chart title, legend, bar spacing, and gridlines. A legend entry for the hidden Start series is usually unnecessary; remove the legend or make the labels clear enough that viewers understand the visible bars represent durations.
Set the date scale and labels
In a stacked-bar Gantt, the horizontal value axis uses Excel’s numeric date values. If the axis begins at zero, the bars may appear tiny or far to the right because modern dates have large serial values. Select the horizontal axis, open Format Axis, and set its minimum bound to the Excel date value for the schedule’s chosen starting point. Excel stores dates as serial numbers, so the minimum must be a numeric date value, not a typed date label in an arbitrary text format. Set it early enough to include every task you want to show.
In the same Format Axis pane, adjust the major unit to control the interval between tick marks. The best interval depends on the schedule: a monthly scale can suit a year-long project, while a weekly scale may be clearer for a short project. Under Number, choose a date format that fits the chart, such as a month-and-year display. If the axis is crowded, widen the chart or reduce the number of displayed date labels rather than shrinking the text until it is difficult to read.
Manually setting the minimum keeps the visual range focused, but it also means you may need to update the bound when new tasks begin earlier than the current minimum. After refresh, inspect the axis and bars. A chart that appears blank can simply have a minimum bound later than the dates in the refreshed data.
Filter and refresh the schedule
One reason to choose a PivotChart is that its PivotTable fields can support interactive views. A Project or Phase filter can show only a portion of the schedule, and a slicer can make that filtering more visible to other readers. To add one, click the PivotTable and choose PivotTable Analyze > Insert Slicer, then select a field such as Project or Owner. A slicer filters the PivotTable and its connected PivotChart.
When the source data changes, refresh the PivotTable by right-clicking inside it and choosing Refresh, or use Data > Refresh All to update workbook connections and PivotTables. If the source is an Excel table, newly added rows are generally included when the PivotTable refreshes. Confirm that the table itself expanded to include the new rows. After refreshing, review the task list, duration totals, chart order, date-axis bounds, and any hidden-series formatting. If the PivotTable includes fields that were not part of the chart design, check that the chart still shows the intended series.
For a presentation, consider hiding PivotChart field buttons after the layout is finished. These buttons are useful while exploring fields but can clutter a finished schedule. They do not replace slicers; keep the controls that the chart’s audience actually needs.
Limitations and alternatives
A PivotChart summarizes data, whereas a Gantt chart is often expected to show each individual task and its exact dates. The PivotTable’s grouping and aggregation are useful for analysis but can merge records or summarize dates in ways that are wrong for a task-by-task plan. Keep one appropriate record per bar, or make separate records for distinct task segments. Do not assume that adding a field to the chart will automatically create task dependencies, milestones, or progress tracking.
PivotCharts also offer less freedom than ordinary charts in some areas, and chart formatting or axis settings may need attention after a refresh or layout change. For a fixed schedule, select the task, start, and duration columns in a normal chart source and create a stacked bar chart instead. The same hidden-start-series technique applies, but there is no PivotTable aggregation layer. For a more sophisticated schedule with dependencies, baselines, resource planning, or automated date changes, a project-management tool may be a better fit than either Excel chart type.
A common misconception is that a PivotChart has a built-in Gantt option that appears after inserting a PivotTable. It does not. The chart remains a stacked bar chart whose appearance is adapted to a schedule. Another is that hiding the start series removes it from the calculation. It does not: the series remains necessary for positioning, so keep it in the chart even when its fill and border are invisible.
Frequently Asked Questions
Does Excel have a built-in Gantt chart?
No. Excel does not include a dedicated Gantt chart type. You can create a Gantt-style display with a stacked bar chart, using a hidden start-date series and a visible duration series.
Can I make a Gantt chart with a PivotChart?
Yes, if the PivotTable provides an appropriate start value and duration for each task. Use a stacked bar PivotChart and hide the start series. A regular chart may be simpler when you do not need PivotTable filtering or summaries.
Why are my Gantt bars missing or too short?
Check that Start contains real Excel dates, Duration contains numbers, and the chart is Stacked Bar rather than 100% Stacked Bar. Also inspect the horizontal-axis minimum; a bound later than the task dates can hide the bars, while a zero minimum can compress them against a very large date scale.
Why does the PivotChart combine two tasks with the same name?
PivotTables group identical row labels together. Give each task a unique ID or a distinct label, then refresh the PivotTable so each intended task appears as its own category.
Will the chart update when I add a task?
Refresh the PivotTable after adding the task. If the source is an Excel table, check that the new row is inside the table, then refresh and review the chart’s axis limits and formatting.
Related
- Excel Shortcut to Go to a Named Range
- Excel Showing Page Break Lines? How to Hide Them
- Excel Shortcut Keys: Examples for Everyday Tasks
Try it: the Percentage Formula Generator: percent of, percent change, increase and decrease, with the formula.
More in Charts & pivot tables
- How to Format a Doughnut Chart in Excel for ClarityTo format a doughnut chart in Excel, select the chart and use the Chart Design tab to change…
- Google Sheets Chart Templates: How to Find and Use ThemGoogle Sheets does not have a dedicated gallery of reusable chart-style templates, but you can start with a…
- Excel Histogram With a Line Chart: How to Build OneYes. In Excel for Microsoft 365 on Windows, the most dependable way to put a line on a…
- Creating a Waterfall Chart in Excel: A Step-by-Step GuideTo create a waterfall chart in Excel for Microsoft 365 on Windows, put each step of the change…
- Excel Copy Pivot Chart: Change Its Data Source Safely?Copying a PivotChart in Excel does not normally give the copy an independent data source: the copied chart…
- Google Sheets Chart Themes: How to Set and CustomizeIn Google Sheets, a chart’s appearance can come from the spreadsheet’s overall theme or from settings on the…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.