Change Excel Chart Category Labels to a Vertical Data Range
Question details
The user wants an Excel chart to use category labels from a vertical range and include data from nonadjacent cells.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- The chart's category labels and values are stored in separate ranges, and the user wants to select them manually without copying them into Excel's default layout.
- Observed behavior
- Excel may interpret the selected source data as rows or columns and assign the wrong cells to the category axis or data series.
Identify the vertical cells containing the category labels and the separate ranges containing the values for each series. Check that each series has the same number of values as there are category labels.
Edit the category labels and series ranges in Excel
Use Select Data to assign a vertical label range and add each nonadjacent series separately.
This changes which cells supply the chart data; it does not rotate the text displayed on the axis. Available options can vary by chart type.
Select the chart, then choose Chart Design > Select Data, or right-click the chart and select Select Data.
Under Horizontal (Category) Axis Labels, select Edit. In Axis label range, select the vertical cells containing the labels, then click OK.
Under Legend Entries (Series), select an incorrect series and click Edit to choose its name and value range. Use Remove for unwanted entries and Add to select each additional series from its own range.
Click OK in Select Data Source and check that the categories and values appear in the intended order.

Switch the chart's rows and columns
Try this when Excel has interpreted the entire source range in the opposite orientation.
Set chart category labels in WPS Spreadsheet
Open your workbook in WPS Spreadsheet and use the chart's data selection controls to choose a vertical category-label range and adjust series ranges.
- 1. Open the workbook: Open WPS Spreadsheet and choose Open to select your Excel workbook.
- 2. Open the chart data controls: Click the chart, then choose Select Data from the chart tools or the chart's right-click menu.
- 3. Set labels and series: In the data selection dialog, edit the category-axis label range to select the vertical label cells. Add or edit each series to select its corresponding values.
- 4. Review and save: Confirm the changes, check the chart, and choose File > Save As to save the workbook in XLSX format.

Frequently Asked Questions
Can I use nonadjacent cells for an Excel chart?
Often you can add separate value ranges as individual series through Chart Design > Select Data > Add. Some chart types or range selections may require a contiguous helper range.
Why is Switch Row/Column unavailable?
The command depends on the chart type and how its data is defined. If it is unavailable, try editing the series and axis ranges through Chart Design > Select Data instead.
Does selecting a vertical range rotate the axis label text?
No. Selecting a vertical range changes the source cells. To rotate displayed text, right-click the axis, choose Format Axis, and look for the text direction or custom angle controls.
Why don't I see Horizontal Category Axis Labels for an XY scatter chart?
An XY scatter chart uses numeric X values for each series rather than a standard category axis. In Select Data, edit each series and specify its X values and Y values separately.




