Logging Arduino Serial Output to CSV/Excel

20 kg load cell
Written by Indrek Luuk

I have written a plugin for Arduino IDE to save serial data as a CSV file that you can open in any spreadsheet application - like Microsoft Excel or LibreOffice.

ArduSpeadsheet Arduino IDE plugin


Extract the zip file and copy the "ArduSpreadsheet" folder into your Arduino "tools" folder next to the Arduino "libraries" folder. If it doesn't exist, then you can create it yourself.

On Windows:
On Mac:
ArduSpeadsheet in Arduino 'tools' folder

Now restart your Arduino IDE, and you should see "ArduSpreadsheet" under the "Tools" menu.

ArduSpreadsheet in the Arduino IDE tools menu

Arduino code

You can use the Arduino Serial library to send data for logging.

The baud rate parameter has to match with the selection in the ArduSpreadsheet window.

void setup() {
ArduSpeadsheet Arduino IDE plugin
For column separation, you can pick one of the three symbols:
  • tab - '\t'
  • comma - ','
  • semicolon - ';'

You can indicate the end of the row by calling "Serial.println()" or printing out a newline symbol '\n'.


int rowCount = 500;
int rowNumber = 0;

void setup() {

void loop() {
  if (rowNumber < rowCount) {
    if (rowNumber % 2 == 0) {
    } else {
    Serial.println(random(16000), HEX);

The above code will produce this result:

ArduSpeadsheet Arduino IDE plugin

Running ArduSpreadsheet as a stand-alone program

To run it as a stand-alone program, you need to install Java 1.8 or newer.

I have included execution scripts for Windows, Mac, and Linux (all they do is execute the Main method inside ArduSpreadsheet.jar).

On Windows

Double-click on the "Windows_ArduSpreadsheet.bat." You may get a warning that you are executing an unrecognized app.

ArduSpreadsheet in the Arduino IDE tools menu

Click on "More info" and then "Run anyway."

ArduSpreadsheet in the Arduino IDE tools menu

On Mac

To get it running on Mac, you first need to give execution privileges to the script file.

Open Terminal application and "cd" into the "ArduSpreadsheet" folder. Now execute:
$ chmod a+x Mac_ArduSpreadsheet.command

Then double-click on the "Mac_ArduSpreadsheet.command."

Mac OS will warn that the application is from an unknown developer.

ArduSpeadsheet Arduino IDE plugin

Open "System Preferences..." and then "Security & Privacy."

You should see:
"Mac_ArduSpreadsheet.command" was blocked from use because it is not from an identified developer.
ArduSpeadsheet Arduino IDE plugin

Click "Open Anyway" and then "Open"

ArduSpeadsheet Arduino IDE plugin

Now you can Open ArduSpreasheet by double-clicking on the "Mac_ArduSpreadsheet.command."

On Linux

Open Terminal application and "cd" into the "ArduSpreadsheet" folder. Now execute:
$ chmod a+x Linux_ArduSpreadsheet.sh

Now you should be able to run the application by either executing the script from the command line or double-clicking on the "Linux_ArduSpreadsheet.sh."