Smart Systems for Home

Plain how-to guides for smart home, security and home Wi-Fi

Excel Paste Special as Text for Long Numbers

· 4 min read · Home Tech

In this article
  1. What You'll Need
  2. Step-by-Step
  3. Common Mistakes
  4. Tips
  5. Troubleshooting
  6. Frequently Asked Questions

To paste long numbers as text in Excel and prevent them from converting to scientific notation (like 1.23E+11) or losing precision, you must format the destination cells as "Text" before pasting the data. Excel automatically treats long strings of digits as numbers, and because it has a 15-digit precision limit, any digit beyond the 15th is permanently changed to a zero unless the cell is explicitly set to Text format first.

What You'll Need

  • Microsoft Excel (Desktop or Web version)
  • The source data (copied from a CSV, website, another spreadsheet, or a text file)

Step-by-Step

  1. Copy your data: Highlight the long numbers in your source document and press Ctrl + C (Windows) or Cmd + C (Mac) to copy them to your clipboard.
  2. Select the destination area: In your Excel worksheet, click and drag to highlight the cells, column, or row where you intend to paste the numbers.
  3. Change the cell format to Text:
    • Go to the Home tab on the top ribbon.
    • Locate the Number group.
    • Click the dropdown menu (which usually says "General" by default).
    • Scroll down and select Text from the list.
  4. Paste the data: With the cells still selected and formatted as Text, right-click on the first cell of the range.
  5. Use Paste Special or Match Destination Formatting:
    • Depending on your version of Excel, select Paste Special... and choose Text or Unicode Text.
    • Alternatively, select the Match Destination Formatting icon (often looks like a clipboard with a small "M" or a plain text icon) to ensure the "Text" format you just applied is not overwritten by the source formatting.
  6. Verify the result: Check that the numbers appear exactly as they did in the source. You will likely see a small green triangle in the top-left corner of the cells; this is simply a warning that a number is being stored as text and can be ignored.

Common Mistakes

  • Pasting before formatting: The most common error is pasting the numbers first and then changing the format to Text. Once Excel converts a long number to scientific notation or replaces the 16th digit with a zero, that data is lost. Changing the format afterward only changes how the corrupted number is displayed; it does not recover the original digits.
  • Using the "Number" format: Selecting "Number" instead of "Text" will not solve the problem for very long strings (like 16-digit credit card numbers). The "Number" format still adheres to the 15-digit precision limit.
  • Double-clicking into a cell: If you double-click into a cell to enter "Edit Mode" before pasting, Excel may ignore the column's Text formatting and treat the input as a General number, triggering the scientific notation conversion.

Tips

  • The Apostrophe Trick: For single entries, you can type a single quote/apostrophe (') before typing or pasting a long number. This tells Excel to treat everything following the apostrophe as text. The apostrophe will not be visible in the cell itself, only in the formula bar.
  • Importing via Data Tab: If you are dealing with a large CSV file, avoid double-clicking the file to open it. Instead, go to the Data tab > Get Data > From File > From Text/CSV. This opens the Power Query editor, where you can explicitly set the data type of the long number column to "Text" before loading it into the sheet.
  • Column Selection: If you know an entire column will contain long IDs, click the column letter (e.g., "A") to select the whole column before applying the Text format. This ensures any future data added to that column remains intact.

Troubleshooting

If your numbers still appear as 1.23E+11 or end in zeros after following these steps, try the following:

  • Clear all formatting: Select the cells, go to the Home tab, click Clear (the eraser icon), and select Clear Formats. Then, re-apply the Text format and paste again.
  • Paste as Plain Text: If you are using Excel for the Web, try using Ctrl + Shift + V to paste values without any source formatting.
  • Check the source: Ensure the source data hasn't already been converted to scientific notation by another program before you copied it. If the source already shows "E+", the original digits are already gone.

Frequently Asked Questions

Why does Excel change my long numbers to scientific notation?

Excel uses scientific notation to save space when a number is too long to fit in a cell. Additionally, Excel follows the IEEE 754 floating-point standard, which limits numerical precision to 15 significant digits.

Will storing numbers as text prevent me from doing math?

Yes, standard formulas like SUM may ignore cells formatted as text. However, for IDs, account numbers, or credit card numbers, mathematical operations are usually not required.

Can I convert these "Text" numbers back to "Numbers" later?

You can change the format back to Number, but if the number exceeds 15 digits, Excel will permanently replace any digit after the 15th with a zero. There is no way to reverse this once the file is saved.

What is the green triangle in the corner of my cell?

This is an "Error Indicator." Excel is notifying you that a value that looks like a number is formatted as text. You can click the warning icon and select "Ignore Error" to remove the triangle.

Does this work for barcodes and SKU numbers?

Yes. Barcodes and SKUs often contain leading zeros (e.g., 000123). Formatting as Text is the only way to prevent Excel from deleting those leading zeros.