# Jira Forge Export Excel file

**URL:** <https://community.developer.atlassian.com/t/jira-forge-export-excel-file/77548>\
**Category:** Forge UI Kit and Custom UI\
**Tags:** export, jira-cloud\
**Created:** [February 21, 2024, 4:18pm UTC](https://community.developer.atlassian.com/t/jira-forge-export-excel-file/77548 "2024-02-21T16:18:42Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![DanielVelkov](https://avatars.discourse-cdn.com/v4/letter/d/919ad9/32.png) [@DanielVelkov](https://community.developer.atlassian.com/u/DanielVelkov)\
**Post date:** [February 21, 2024, 4:18pm UTC](https://community.developer.atlassian.com/t/jira-forge-export-excel-file/77548/1 "2024-02-21T16:18:42Z")

</div>

Hello,  
We need to implement an export button for some table data we generate from the issues object.  
Is that possible? What are the allowed formats?  
I tried an implementation using the file-saver and exceljs packages but it seems forge doesn’t allow npm packages other than @forge/ui

---

<div class="post-metadata">

**Author:** ![ibuchanan](https://sea1.discourse-cdn.com/atlassiandeveloper/user_avatar/community.developer.atlassian.com/ibuchanan/32/35815_2.png) [@ibuchanan](https://community.developer.atlassian.com/u/ibuchanan)\
**Post date:** [February 21, 2024, 8:13pm UTC](https://community.developer.atlassian.com/t/jira-forge-export-excel-file/77548/2 "2024-02-21T20:13:35Z")

</div>

Welcome to the Atlassian developer community @DanielVelkov,

> [@DanielVelkov](#):
>
> We need to implement an export button for some table data we generate from the issues object.  
> Is that possible?

Possible, but only as a distinct feature, not associated with existing export capabilities. See this recent discussion:

> [@How to add menu item to the Export Issues menu](https://community.developer.atlassian.com/t/how-to-add-menu-item-to-the-export-issues-menu/76192):
>
> Hello, I would like to add a menu item in the Export Issues menu (in the Issues page ) and the Export menu (in the Search page) or a new Menu next to the Export Issues one. I don’t see a module in Forge to do that. Is there a way to do it? Thanks, Edgar

> [@DanielVelkov](#):
>
> What are the allowed formats?  
> I tried an implementation using the file-saver and exceljs packages but it seems forge doesn’t allow npm packages other than @forge/ui

It isn’t so much that there is an explicit set of “known formats”. Rather that you will have some limitations based on the Forge environment.

In the currently GA runtime, you are limited by Atlassian’s proprietary Node-like implementation. While [our documentation has a pretty exhaustive list of limitations](https://developer.atlassian.com/platform/forge/runtime-reference/), we are aware that it’s often hard to know if those limitations apply to a specific library. You might have to probe the dependency tree pretty hard to know if and why a particular library doesn’t work.

Fortunately, there is a new [Forge native Node.js runtime](https://developer.atlassian.com/platform/forge/runtime-reference/native-nodejs-runtime) that helps solve these problems:

> The new _native Node.js runtime_ enables Forge functions to run within a standard Node.js environment. This will allow you to import any built-in, local, or third-party Node modules into your app.

You might try using your libraries in that runtime instead.

That said, you still don’t have full access to the infrastructure, which some libraries might assume. For example, you won’t have a way to just “drop a file” on disk and pick it up outside the Forge App. So you will still want to be aware of [the new runtime’s limitations](https://developer.atlassian.com/platform/forge/runtime-reference/native-nodejs-runtime/#known-limitations).

---

<div class="post-metadata">

**Author:** ![DanielVelkov](https://avatars.discourse-cdn.com/v4/letter/d/919ad9/32.png) [@DanielVelkov](https://community.developer.atlassian.com/u/DanielVelkov)\
**Post date:** [February 22, 2024, 9:44am UTC](https://community.developer.atlassian.com/t/jira-forge-export-excel-file/77548/3 "2024-02-22T09:44:16Z")

</div>

Thanks for the quick and thorough answer. I changed the project to that runtime and it at least deploys, but the file-saver “saveAs” function doesn’t work. It doesn’t throw any error nor download the file. I am using the latest package versions for forge, file-saver and excelJS. Here is the code:

```auto
const workbook = new excelJs.Workbook();
const worksheet = workbook.addWorksheet('Report Data');
workbook.xlsx.writeBuffer().then( (buffer) => {
      const blob = new Blob([buffer], { type: "applicationi/xlsx" });
      saveAs(blob,"Worklogs.xlsx");
    });

```

---

<div class="post-metadata">

**Author:** ![DanielVelkov](https://avatars.discourse-cdn.com/v4/letter/d/919ad9/32.png) [@DanielVelkov](https://community.developer.atlassian.com/u/DanielVelkov)\
**Post date:** [March 1, 2024, 7:34am UTC](https://community.developer.atlassian.com/t/jira-forge-export-excel-file/77548/4 "2024-03-01T07:34:38Z")

</div>

Has anyone tried something like this?  
@ibuchanan any follow up to your answer?

---

<div class="post-metadata">

**Author:** ![rcsr](https://sea1.discourse-cdn.com/atlassiandeveloper/user_avatar/community.developer.atlassian.com/rcsr/32/50184_2.png) [@rcsr](https://community.developer.atlassian.com/u/rcsr)\
**Post date:** [March 1, 2024, 8:17am UTC](https://community.developer.atlassian.com/t/jira-forge-export-excel-file/77548/5 "2024-03-01T08:17:29Z")

</div>

> [@DanielVelkov](#):
>
> `applicationi/xlsx`

You have a typo. Maybe it’ll work if you fix it. If not maybe try exporting it as a CSV instead - that way you can bypass the need to rely on an external library that Forge may or may not support.

We are developing a custom UI app that also allows users to export data and it works for us when exporting as JSON. Here’s a snippet that maybe you can test out:

```tsx
  const jsonData = JSON.stringify(exportData);
  const blob = new Blob([jsonData], { type: 'application/json' });

  // Create a download link
  const url = URL.createObjectURL(blob);
  const download = `data.json`;

  return (
    <Button appearance='link' href={url} download={download}>
      Export summary
    </Button>
  );

```

**Edit:** Oh nevermind, I thought you were using custom UI but it looks like you’re using UI kit?

---

<div class="post-metadata">

**Author:** ![DanielVelkov](https://avatars.discourse-cdn.com/v4/letter/d/919ad9/32.png) [@DanielVelkov](https://community.developer.atlassian.com/u/DanielVelkov)\
**Post date:** [March 1, 2024, 11:38am UTC](https://community.developer.atlassian.com/t/jira-forge-export-excel-file/77548/6 "2024-03-01T11:38:22Z")

</div>

Yes I am using UI Kit. Maybe that’s the root of the problem.

---

<div class="post-metadata">

**Author:** ![CaterinaCurti](https://sea1.discourse-cdn.com/atlassiandeveloper/user_avatar/community.developer.atlassian.com/caterinacurti/32/42270_2.png) [@CaterinaCurti](https://community.developer.atlassian.com/u/CaterinaCurti)\
**Post date:** [November 25, 2024, 1:21am UTC](https://community.developer.atlassian.com/t/jira-forge-export-excel-file/77548/7 "2024-11-25T01:21:18Z")

</div>

Hi @DanielVelkov,  
Not sure if this is still relevant but I just gave this a try with [UI Kit](https://developer.atlassian.com/platform/forge/ui-kit) (note that this is the new one, the previous one is now called [UI Kit 1](https://developer.atlassian.com/platform/forge/ui-kit-components/previous_versions/)) and everything is working fine for me.

I would love to know more about use case too, if you can share which data you are trying to export and maybe (no guarantee but I’ll try) I can create a sample app for that.

I tested it started from this sample app for Bitbucket [Instantly Access and Share Repository Size Data Across All Projects](https://community.atlassian.com/t5/Forge-for-Bitbucket-Cloud/Instantly-Access-and-Share-Repository-Size-Data-Across-All/ba-p/2877076), the source code is available [here](https://bitbucket.org/atlassian/forge-bitbucket-reports/src/main/01.RepositorySize/).

The source code is for a CSV export. The only modifications I did to the app were in the [frontend/workspace-settings.jsx](https://bitbucket.org/atlassian/forge-bitbucket-reports/src/main/01.RepositorySize/src/frontend/workspace-settings.jsx) file:

- I added the `import ExcelJS from 'exceljs';`
- Changed the `Download` Button to use the `downloadExcelFile` function:

```auto
<Button onClick={downloadExcelFile}>Download Excel</Button>

```

- Added the `downloadExcelFile` function:

```auto
  // Download the Excel file
  const downloadExcelFile = async () => {
    console.log('Downloading Excel file');
    if (!unformattedRows) return;

    const workbook = new ExcelJS.Workbook();
    const worksheet = workbook.addWorksheet('Repositories');
    worksheet.columns = [
      { header: 'Project', key: 'project' },
      { header: 'Name', key: 'name' },
      { header: 'Size (bytes)', key: 'size' },
    ];

    unformattedRows.forEach(repo => {
      worksheet.addRow(repo);
    });

    const buffer = await workbook.xlsx.writeBuffer();
    const blob = new Blob([buffer], { type: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' });
    const url = URL.createObjectURL(blob);

    const element = document.createElement("a");
    element.href = url;
    element.download = 'repositories.xlsx';
    document.body.appendChild(element); // Required for this to work in FireFox
    element.click();
  };

```

Cheers,  
Caterina

---

<div class="post-metadata">

**Author:** ![Mikasonu](https://avatars.discourse-cdn.com/v4/letter/m/ecb155/32.png) [@Mikasonu](https://community.developer.atlassian.com/u/Mikasonu)\
**Post date:** [December 18, 2024, 12:21pm UTC](https://community.developer.atlassian.com/t/jira-forge-export-excel-file/77548/8 "2024-12-18T12:21:56Z")

</div>

So, it’s pretty simple if you’re working with a Jira Forge export and want to split the date and time in Excel. You can use the “Text to Columns” feature in Excel. Select the column with your date-time values, go to the “Data” tab, and click “Text to Columns.” Choose “Delimited,” then use the space as the delimiter to separate the date from the time. After that, you’ll have two columns—one with just the date and the other with the time. If you need them in different formats, you can use the “DATE” and “TIME” functions to fine-tune them. Here’s a helpful guide for more details on [how to separate date and time in excel](https://www.myexcelonline.com/blog/separate-date-and-time/).

---

<div class="post-metadata">

**Author:** ![Corentin](https://sea1.discourse-cdn.com/atlassiandeveloper/user_avatar/community.developer.atlassian.com/corentin/32/50121_2.png) [@Corentin](https://community.developer.atlassian.com/u/Corentin)\
**Post date:** [December 23, 2025, 10:56am UTC](https://community.developer.atlassian.com/t/jira-forge-export-excel-file/77548/9 "2025-12-23T10:56:12Z")

</div>

Hi @CaterinaCurti it seems like the source code repository at `https://bitbucket.org/atlassian/forge-bitbucket-reports/src/main/` is not accessible for non-atlassians.

Could you have a look and push the source to a public repo?

Thanks a lot, Corentin.
