---
title: "Rearranging column order in Google Sheets using Google Apps Script"
author: "Martin Hawksey"
date: 2023-03-13T22:11:46+00:00
canonical_url: https://pulse.appsscript.info/p/2023/03/rearranging-column-order-in-google-sheets-using-google-apps-script/
markdown_url: https://pulse.appsscript.info/p/2023/03/rearranging-column-order-in-google-sheets-using-google-apps-script.md
categories:
  - "Beginner"
  - "Sheets"
  - "Snippet"
tags:
  - "tanaikech.github.io"
featured_image: https://pulse.appsscript.info/files/2023/03/fig1.png
description: "Following on from the recent example from Scott Donald on How to sort tabs in Google Sheets with Google Apps Script, here is a handy little snippet from Kanshi Tanaike for changing the column order in Google Sheets using Apps Script and the moveColumns method."
---

# Rearranging column order in Google Sheets using Google Apps Script

![Rearranging column order in Google Sheets using Google Apps Script](https://pulse.appsscript.info/files/2023/03/fig1.png)

> [https://tanaikech.github.io/2022/12/21/rearranging-columns-on-google-spreadsheet-using-google-apps-script/](https://tanaikech.github.io/2022/12/21/rearranging-columns-on-google-spreadsheet-using-google-apps-script/)
> This is a sample script for rearranging columns on Google Spreadsheet using Google Apps Script.

Following on from the recent example from Scott Donald on [How to sort tabs in Google Sheets with Google Apps Script](https://pulse.appsscript.info/p/2023/03/how-to-sort-tabs-in-google-sheets-with-google-apps-script/), here is a handy little snippet from Kanshi Tanaike for changing the column order in Google Sheets using Apps Script and the [`moveColumns`**](https://developers.google.com/apps-script/reference/spreadsheet/sheet#movecolumnscolumnspec,-destinationindex) method.

Source: [Rearranging Columns on Google Spreadsheet using Google Apps Script**](https://tanaikech.github.io/2022/12/21/rearranging-columns-on-google-spreadsheet-using-google-apps-script/)

---

*Published by [Martin Hawksey](https://pulse.appsscript.info/p/author/admin/) on [Pulse](https://pulse.appsscript.info/). Original article: [https://pulse.appsscript.info/p/2023/03/rearranging-column-order-in-google-sheets-using-google-apps-script/](https://pulse.appsscript.info/p/2023/03/rearranging-column-order-in-google-sheets-using-google-apps-script/)*
