Random sort a Google Sheet easily

Published: 2016-12-08 10:58 |

Category: Technology |


I was working on student grades in a Google Sheet last night and I needed an easy way to randomly sort students so I could show some score adjustments. Sheets lets you sort A-Z and Z-A easily, but there’s no baked in random function, which makes sense.

I could have scripted it, but it was late and I was feeling lazy. There’s an easier method.

Grab a column and enter =rand(). This will generate a random number between 0 and 1. Click and drag this down the entire range. Then, sort this column A-Z. Hey presto! Random sorting a Sheet.

Notice that the random column changes every time something else is clicked. This won’t affect anything other than the sorting, but it allows you to resort if it isn’t “random enough.”

I’ve been ruminating on a way to use Sheets and Google Apps Script as a fully-functional gradebook. I’m not there yet, but I can see this being helpful in that implementation.

Comments are always open. You can get in touch by sending me an email at brian@ohheybrian.com