To create a Gantt chart in Excel, you start with a table of tasks, start dates, and durations, then build a stacked bar chart and format it so the first series is invisible. This turns a basic bar chart into a timeline view of your project. No special add-ins are required—everything is done with standard Excel features.
What You'll Need
- Microsoft Excel (2013 or later; the steps are similar across versions, but menu names may differ slightly).
- A list of your project tasks, their start dates, and how many days each task will take.
- Basic familiarity with selecting cells and using the ribbon menus.
Step-by-Step
- Prepare your data table. In a new worksheet, create three columns: Task, Start Date, and Duration (Days). Enter each task in its own row, with the start date as a real date (e.g., 3/1/2025) and the duration as a number (e.g., 5). For example:
Task | Start Date | Duration
Research | 3/1/2025 | 5
Design | 3/6/2025 | 10
Development | 3/16/2025 | 15
Testing | 3/31/2025 | 7 - Add a helper column for the chart. Insert a new column between Start Date and Duration (or to the right) called Days Before Start. This will hold the number of days from the project start to each task's start date. In the first data row, enter
=B2-MIN($B$2:$B$10)(adjust the range to your data). Drag the formula down for all tasks. This gives you the offset from the earliest start date. - Select the data for the chart. Highlight the Task column, the Days Before Start column, and the Duration column. To select non-adjacent columns, hold Ctrl while clicking the column headers. Include the header row if you want the names to appear in the legend.
- Insert a stacked bar chart. Go to the Insert tab, click Bar Chart (or the bar chart icon in the Charts group), and choose Stacked Bar (the first option under 2-D Bar). Excel will create a chart with two series: one for Days Before Start and one for Duration.
- Make the first series invisible. Click on the chart to select it, then click on the series that represents the Days Before Start (these are the bars on the left). Right-click and choose Format Data Series. In the panel that opens, go to Fill and select No fill. Then go to Border and select No line. This hides the offset bars, leaving only the duration bars visible.
- Reverse the vertical axis. By default, Excel plots the first task at the bottom. To have the first task appear at the top (like most Gantt charts), right-click on the vertical axis (the task names) and choose Format Axis. In the Axis Options panel, check the box Categories in reverse order. This also moves the horizontal axis to the top, which is fine—we'll fix that next.
- Adjust the horizontal axis dates. Right-click on the horizontal axis (the numbers at the top) and choose Format Axis. In the Axis Options, set the Minimum to the earliest date in your project (e.g., 3/1/2025) and the Maximum to the latest date plus a few days. To do this, change the Minimum and Maximum to Fixed and enter the date serial numbers (e.g., for 3/1/2025, type 45687 if that's the serial number—but you can also type the date directly in the box and Excel will convert it). Make sure the dates are in the same format as your data.
- Remove the legend. If you don't want the legend (which now shows “Days Before Start” and “Duration”), click on it and press Delete. The chart is clearer without it.
- Format the bars. Click on the duration bars (the visible ones). Right-click and choose Format Data Series. Under Fill, choose a solid color. Under Gap Width (in the Series Options), set it to something like 30% to make the bars thicker and more readable.
- Add data labels (optional). To show the duration on each bar, right-click on the bars and choose Add Data Labels. Then right-click on the labels and select Format Data Labels. Check Value (or Value From Cells if you want to show the task name). You can also position the labels at the end of the bars.
- Clean up the chart. Remove gridlines if they clutter the view (click on them and press Delete). Adjust the chart title by clicking on it and typing a meaningful name like “Project Timeline”. Resize the chart by dragging its corners.
Common Mistakes
- Using the wrong chart type: A regular bar chart (not stacked) will not work because you need the offset series to create the timeline effect.
- Not reversing the axis: If you skip step 6, your tasks will appear bottom-up, which is confusing.
- Forgetting to set the axis minimum: If you leave the horizontal axis auto, it might start at zero or at a date that cuts off your first task. Set it manually to your project start.
- Entering dates as text: If you type “3/1” and Excel doesn't recognize it as a date, the chart will show numbers instead. Ensure your start dates are actual date values (right-click the cell, Format Cells, Date).
- Including the header in the data selection incorrectly: If you select the entire columns including headers, Excel may treat the header as a data point. Select only the data rows, or include headers but ensure they are text.
Tips
- Use a table: Convert your data range to an Excel Table (Ctrl+T). This makes it easier to add or remove tasks, and the chart will update automatically if you use structured references.
- Freeze the first row: If your project has many tasks, freeze the top row so you can see the column headers while scrolling.
- Add a vertical line for today: To show the current date, add a vertical line using a secondary axis or a line chart overlay. A simpler method is to add a data point on a separate series and use error bars, but that's advanced. For most purposes, a simple colored cell or a text box is enough.
- Use conditional formatting for overdue tasks: You can highlight tasks that are past their end date by using a formula in conditional formatting. For example, select the duration cells, go to Home > Conditional Formatting > New Rule, and use a formula like
=AND($B2+TODAY()>TODAY(), $B2+$C2to highlight tasks that should have finished but haven't. - Save a template: Once you have a nicely formatted Gantt chart, save the workbook as an Excel Template (.xltx) so you can reuse it for future projects.
Troubleshooting
My chart shows only one series or the bars are all the same color. This usually means you didn't select both the Days Before Start and Duration columns. Click on the chart, go to the Chart Design tab, and choose Select Data. In the left panel, add the Duration series and edit the Days Before Start series to point to the correct range.
The dates on the horizontal axis look like numbers (e.g., 45687). This happens when the axis is set to a number format instead of a date. Right-click the axis, choose Format Axis, and under Number, select Date and choose your preferred format.
My tasks are in the wrong order (newest at top). You reversed the axis, but you also need to make sure your data is sorted by start date ascending. If you sort your table by start date, the chart will follow that order.
The bars are too thin or too thick. Right-click on the bars, go to Format Data Series, and adjust the Gap Width. Lower gap width makes bars thicker.
I see an extra series called “Days Before Start” in the legend. That's the invisible series. If you didn't remove the legend, you'll see it. Delete the legend or hide the series by selecting it and pressing Delete (but that will remove the data, so instead just remove the legend).
My chart doesn't update when I change data. If you used a normal range, Excel should update automatically. If not, go to Formulas > Calculation Options and set to Automatic. Also, ensure your chart's data range includes the new rows (if you added rows, you may need to adjust the range via Select Data).
Frequently Asked Questions
Can I create a Gantt chart in Excel without the stacked bar trick?
No, the stacked bar with a hidden series is the standard method. There is no built-in Gantt chart type in Excel, but this workaround is reliable and widely used.
Can I use Excel on a Mac to make a Gantt chart?
Yes, the steps are essentially the same in Excel for Mac. The ribbon layout is slightly different, but you'll find the same chart types and formatting options.
How do I show the task name on the bar instead of the duration?
Right-click on the bars, choose Add Data Labels, then right-click on the labels and select Format Data Labels. Check Value From Cells and select the range containing the task names. Uncheck other options like Value.
Can I add dependencies (arrows) between tasks?
Excel does not have a simple way to draw arrows that move with the bars. You can insert shapes (arrows) manually, but they won't stay attached if you move the bars. For complex dependencies, consider using a dedicated project management tool.
Why does my chart show dates as numbers like 45687?
That's the serial number for the date. Right-click the axis, go to Format Axis, then under Number, select Date and pick a date format.
Can I use this method for a project with hundreds of tasks?
Yes, but the chart may become cluttered. You can filter your table to show only summary tasks, or use a separate chart for each phase. Excel can handle up to about 1,000 data points in a chart, but readability suffers long before that.