Excel SORTBY Function | Excel One Minute Quick Reference

Posted on:  10/18/2021
Excel SORTBY Function  |  Excel One Minute Quick Reference

The SORTBY function in Excel sorts the contents of a range or array based on the values in a corresponding range or array. Use SORTBY to see a list of employees sorted by highest paid, but you don't show their salaries. USE SORTBY to sort a customer list by the most profitable customer but not see the revenue. 

SORTBY has two required arguments, but you can sort by multiple criteria. You can use the SORTBY function on another worksheet or on another file or workbook.

SORTBY function in Excel

SORTBY Function in Excel

YouTube video

Other Excel articles

Syntax for SORTBY

 

=SORTBY(array, by_array1, [sort_order1], [by_array2, sort_order2],…)

 

Arguments for SORTBY

  • array - The array or range to sort - Required
  • by_array1 - The array or range to sort on - Required
  • [sort_order1] - The order to use for sorting. 1 for ascending, -1 for descending. Default is ascending.
  • [by_array2] - The array or range to sort on
  • [sort_order2] - The order to use for sorting. 1 for ascending, -1 for descending. Default is ascending

Versions of Excel the SORTBY function works in

  • Excel for Microsoft365
  • Excel for Microsoft 365 for Mac
  • Excel for the web
  • Excel 2021
  • Excel 2021 for Mac
  • Excel for iPad
  • Excel for iPhone
  • Excel for Android tablets
  • Excel for Android phones

Latest Excel articles

Mastering Excel Slicers: A Comprehensive Guide

Mastering Excel Slicers: A Comprehensive Guide

Mastering Loan Amortization: A Comprehensive Guide to Understanding and Comparing Loans

Mastering Loan Amortization: A Comprehensive Guide to Understanding and Comparing Loans

Analyzing 50+ Years of Mortgage Rates in Excel: Insights and Trends

Analyzing 50+ Years of Mortgage Rates in Excel: Insights and Trends

Social Security - Breakeven point in Years using Excel

Social Security - Breakeven point in Years using Excel

Creating a Column Chart using S&P 500 data with Positive and Negative Colors in Excel

Creating a Column Chart using S&P 500 data with Positive and Negative Colors in Excel

Optimizing Excel Formulas with Copilot: A Comprehensive Guide

Optimizing Excel Formulas with Copilot: A Comprehensive Guide

Chris Menard

Chris Menard is a Microsoft Trainer (MCT) and works as a full-time Trainer at BakerHostetler - one of the largest law firms in the US. Chris runs a YouTube channel with 900+ technology videos that cover various tools such as Excel, Word, Zoom, Teams, Gmail, Copilot, Google Calendar, and Outlook. To date, the channel has helped over 20 million viewers. Menard also does 2 to 3 public speaking events yearly, presenting at the Administrative Professional Conference (APC), the EA Ignite Conference, the University of Georgia, and CPA conferences. You can connect with him on LinkedIn at https://chrismenardtraining.com/linkedin or watch his videos on YouTube at https://chrismenardtraining.com/youtube.

Categories