Skip to main content

Extract & File: Sort Files into Client Folders Automatically

Drop files into one folder and let Stax.ai move each one into the right company's folder based on its file name.

Written by Andrew Flowers

Overview

Extract & File sorts a folder full of files for you. You drop files into one folder in Files, and Stax.ai moves each file into the right company's folder based on the file's name.

It's built for TPA teams who collect lots of documents in one place (like year-end uploads) and then spend time filing them one by one. Stax.ai only moves a file when it finds one clear match, so nothing gets filed in the wrong place.

Key benefits

Save hours of manual filing. Year-end season brings in stacks of plan documents, census files and statements. Instead of dragging each file into each client's folder, you run Extract & File once and the matched files land where they belong.

No guessing, no surprises. If a file name doesn't match a record, or matches more than one, Stax.ai leaves that file right where it is and tells you why. You only file the leftovers by hand.

Your existing files are safe. Extract & File never writes over a file. If a file with the same name is already in the destination, Stax.ai keeps both, using the same naming rules Files already uses for duplicates.

Run it by hand or let it run for you. Use the Extract & File button on any open folder for a one-time cleanup, or add the Extract & File automation to a task so filing happens as part of your workflow.

How matching works

Each run matches on one thing. You choose it in the Match on setting:

Match on

How the file name must look

Example file name

Plan ID

Exactly the plan ID, with the same capital letters

ACME401K.pdf

Plan name

Exactly the plan name, with the same capital letters

Acme Corp 401(k) Plan.pdf

Company name

The company name. Capital letters, punctuation and endings like Inc or LLC don't matter, and small typos still count

acme corp.pdf

Company website

The full website. www. and https:// don't matter, and small typos still count

acmecorp.com.pdf

Company EIN

Exactly the EIN as it's saved in Stax.ai, including the hyphen

12-3456789.pdf

A few things to know:

  • Stax.ai looks at the file name only. It does not open or read what's inside the file.

  • For Plan ID, Plan name and Company EIN, the whole file name (not counting the extension, like .pdf) must be the value and nothing else. A file named ACME401K 5500.pdf will not match plan ID ACME401K.

  • Stax.ai only matches against your own team's plans and companies.

  • Files are moved, not copied. Once a file is filed, it's no longer in the starting folder.

Run Extract & File from a folder

  1. Open Files from the left-hand menu.

  2. Open the folder that holds the files you want to sort (for example, a folder called Year-End Uploads).

  3. Click Extract & File on the folder card.

    • A settings panel opens. The folder you have open is already set as the source.

    • The panel starts fresh every time. It does not remember the settings from your last run.

  4. Choose one option under Match on: Plan ID, Plan name, Company name, Company website or Company EIN.

  5. Choose the destination subfolder. This is the folder inside each matched company's folder where files should go (for example, Plan Docs/2025).

    • When you match on Plan ID or Plan name, the file goes into the folder of the company that owns that plan.

    • If the subfolder doesn't exist yet for a company, Stax.ai creates it for you.

  6. Click Run.

  7. Review the results. You'll see two lists:

    • Moved: each file that was filed, and the folder it went to.

    • Not moved: each file that stayed behind, and the reason (No match or More than one match).

Any files listed under Not moved are still in your source folder, ready for you to rename and run again, or to file by hand.

Run Extract & File as an automation

Use the automation when you want filing to happen as part of a task, without anyone clicking a button.

  1. Open the task you want to use.

  2. Attach the Extract & File automation to the task.

  3. Set the source. You can either type the path of the folder to pull files from, or choose a data field that points to that folder.

  4. Choose one option under Match on.

  5. Choose the destination subfolder inside each matched company's folder.

  6. Save the task.

  7. Check the results after the automation runs. The automation's result on the task lists each file as Moved (with where it went) or Not moved (with the reason).

Checking where a file went

Every move is recorded on the file itself. To see it:

  1. Open the file in its new folder.

  2. Open its activity history.

  3. Look for the "Moved" entry, which shows the folder the file was moved into.

Tips for naming files so they match

The better your file names, the more files Stax.ai can file for you.

  • Name the file the value, and only the value. For Plan ID, Plan name and EIN, the file name must be exactly that value. ACME401K.pdf works. ACME401K census.pdf and 2025 ACME401K.pdf do not.

  • Match capital letters for Plan ID and Plan name. ACME401K.pdf matches plan ID ACME401K, but acme401k.pdf does not.

  • Keep the hyphen in EINs. Use 12-3456789.pdf, not 123456789.pdf.

  • Plan ID and EIN are the safest choices. They are unique to one record, so you're less likely to see "More than one match." Plan names and company names can be shared or very similar.

  • Copy values straight from Stax.ai. Copying the plan ID, plan name or EIN from the record itself avoids small typos that stop an exact match.

  • Ask clients to use your naming. If clients upload files for you, share a simple rule like "name each file with your EIN, for example 12-3456789.pdf."

  • Use one Match on choice per batch. Each run checks one kind of value. If some files are named by plan ID and others by EIN, run Extract & File once for each.

Troubleshooting and FAQ

A file says "No match." What happened?

Stax.ai couldn't find a plan or company on your team whose value matches the file name. Check that:

  • You picked the right Match on option for how the file is named.

  • For Plan ID, Plan name and EIN, the file name is exactly the value, with the same capital letters and no extra words.

  • For EIN, the hyphen is included.

  • The plan or company exists in Stax.ai and the value on the record is filled in and correct.

Rename the file and run Extract & File again.

A file says "More than one match." What does that mean?

The file name matched two or more records, so Stax.ai didn't guess. This can happen when two plans share the same name, or when two companies have very similar names or the same website. The message lists the records it matched. Try matching on Plan ID or EIN instead, or file it by hand.

Is it safe to run Extract & File on the same folder again?

Yes. Files that were already filed are no longer in the folder, so only the leftovers are checked again. Nothing gets moved twice.

What if a file with the same name is already in the destination folder?

Stax.ai never overwrites a file. Both files are kept, and the new one gets a slightly different name (like adding "(2)") using the normal Files rules. Note: The results list shows the file's original name, so look for the new name in the destination folder.

Does Extract & File copy my files?

No. It moves them. The file leaves the source folder and goes to the matched company's folder. You can see the move in the file's activity history.

Does it read what's inside my files?

No. Extract & File only looks at file names. It doesn't open files or use AI to guess where they belong.

Does it sort files inside subfolders of my source folder?

No. It only sorts files that sit directly in the folder you run it on. Move any files from subfolders up into the main folder first.

I ran it on an empty folder and got a message.

Extract & File needs at least one file in the folder to run. Add your files and try again.

Is there a limit on how many files I can sort at once?

No. You can run Extract & File on a folder of any size.

Why does the panel forget my settings?

This is on purpose. Each run starts fresh so an old setting doesn't file a new batch the wrong way. Only the source folder is filled in for you.

We renamed a company. Where do its files go?

Files go into the folder that company already has, even if the folder still uses the old name.

Can it file into another team's folders?

No. Stax.ai only matches against your own team's plans and companies.

Related articles

  • Files Overview

  • Navigating and Organizing Files

  • Automations Overview

Did this answer your question?