Sort Node — drag to reorder fields

Similar to SET "order" feature request , I’ve noticed that the Sort node doesn’t seem to let me reorder fields. When I asked the n8n AI it initially told me I could drag and drop to reorder, but on further questioning it said this:

Currently, the n8n documentation does not mention a drag-and-drop feature for reordering the “Fields To Sort By” in the Sort node. The UI only allows you to add or delete fields, not rearrange them by dragging.

To change the order, you will need to:

  1. Delete the fields and re-add them in the desired order (top field is sorted first, then the next, etc.).

  2. Use the “Add Field To Sort By” button to add each field in the correct order.

If you have a lot of fields, it can be a bit tedious, but this is the current method supported in n8n as of version 2.1.4.

Can we have a less tedious way to do this?

Unlike the Set node, where order can be unimportant, field order is very important for the sort node because it determines which sorting rules apply first (unless I’m completely misunderstanding how the node works).

Here’s the workaround I’m using in the meantime. This is to move a new field to the top of the list, but a similar process should work to move new or existing fields to any spot:

  1. Add a new field at the bottom of the list, but leave the Field Name blank.

  2. Cut the field name out of the field above it (the previous last field) and paste into the new blank field

  3. Repeat this for all other fields, moving each field name down by one and bubbling the blank up through the list

  4. Once the blank field reaches the top, fill it in with the sort term you wanted in that position.

  5. Edit the Ascending/Descending order settings on each field to match the fields they’re now sorting by (i.e. move those settings all down by one as well).

+1

@Isikyus_BN’s workaround works, but… 5 steps to move a single field isn’t really sustainable when you’re iterating on complex workflows.

What makes it even more frustrating is that Sort is precisely THE node where order matters. With Set, sure, often you don’t care. But with multi-criteria sorting, the order defines the entire logic.

No need for full drag-and-drop either — just two ↑/↓ buttons on each row would do the job.

1 Like