Others

How to Sort Blocks of Rows and Columns Alphabetically in WPS Office Spreadsheet

Elise WilliamsElise Williams Nov 13, 2026 869 views

Question details

The user needs to alphabetically sort blocks of rows and columns in a WPS Office spreadsheet without separating each row's related values.

How to Sort Blocks of Rows and Columns Alphabetically in WPS Office Spreadsheet
Product
WPS Office Spreadsheet
Device & OS
not provided
Scenario
The user is working with a spreadsheet data block and wants to sort records alphabetically by a key column while keeping all related cells in each row together, adding secondary sort levels or sorting separate blocks when necessary.
Observed behavior
Sorting a single column alone can disassociate records; selecting the full data block and choosing the key column is required to keep row relationships intact.
Before you start

Before sorting, check that each block has a clear header row and no blank rows or columns inside the selected range. If you have separate blocks, leave a blank row or column between them or select each block independently.

Solution 1Recommended

Sort a Data Block Alphabetically by a Key Column

Use this method when you have one continuous block and need to sort rows alphabetically without splitting related values.

Sorting the complete block tells WPS Office to treat the selected rows as one unit, so each row's values move together. If you sort only the key column, the other columns stay in place and records become disassociated.

1
Select the entire data block

Click any cell in the data block, then press Ctrl+A or drag to select all rows and columns that belong together, including the header row.

2
Open the Sort dialog

Go to the Data tab in WPS Office and click Sort.

3
Choose the alphabetical key column

Under Sort by, select the column containing the names or values to sort alphabetically. Keep Sort On set to Values and choose A to Z under Order.

4
Add secondary sort levels if needed

Click Add Level, choose the next column under Then by, set Values, and select A to Z or Z to A for the secondary order.

5
Apply the sort

Click OK. WPS Office sorts the selected block alphabetically and keeps each row's related cells together.

Sort a Data Block Alphabetically by a Key Column
Rows remain linked: After sorting, each row's values move as a unit and the selected block is ordered alphabetically by the key column.
WPS Office Spreadsheet

Sort Data Blocks Alphabetically in WPS Office Spreadsheet

Use WPS Office Spreadsheet to select a complete data block, open Data > Sort, choose the key column, set A to Z, and add levels for secondary sorting. It keeps related rows together and preserves .xlsx Excel format compatibility.

  1. 1. Open your workbook in WPS Office: Launch WPS Office and open the Excel-compatible spreadsheet that contains the data blocks.
  2. 2. Select the full data block: Click inside the block and press Ctrl+A, or drag to select all rows and columns that belong together.
  3. 3. Open Data > Sort: Go to the Data tab and click Sort to open the sorting dialog.
  4. 4. Choose the key column and order: Under Sort by, select the alphabetical key column, set Sort On to Values, and choose A to Z.
  5. 5. Add a secondary level and confirm: If needed, click Add Level for another column, then click OK to apply the sort.
Keeps related rows together when sorting by a key columnSupports multi-level and left-to-right sorting in WPS Office SpreadsheetReads and saves .xlsx and .xls files with Microsoft Excel compatibilityFree, familiar Data and Sort ribbon tools for easy migration
microsoft office alternative - wps office

Frequently Asked Questions

Can I sort only one column alphabetically in WPS Office?

Yes, but if you select only one column and sort it, the other columns stay in place and the row records become disassociated. To keep related values together, select the entire data block before sorting.

How do I add a secondary sort level in WPS Office?

In Data > Sort, click Add Level, choose the second column under Then by, set Sort On to Values, and select A to Z before clicking OK.

How do I keep the header row from being sorted?

Include the header row in your selection and check My data has headers in the Sort dialog. This tells WPS Office to exclude the header from the alphabetical order.

Can WPS Office sort separate data blocks independently?

Yes. Select each block one at a time and sort it separately, leaving blank rows or columns between blocks out of the selection. You can also convert each block to a table for clearer boundaries.

Does WPS Office support sorting columns from left to right?

In Data > Sort, click Options, choose Sort left to right, and then select the row that contains the labels to sort. This reorders columns alphabetically based on that row.