How to Remove Macro from Personal.xlsb Files? Explained

How to Remove Macro from Personal.xlsb Files? Explained

If you've ever recorded or created macros in Excel, you might have noticed a hidden file called Personal.xlsb. This is your Personal Macro Workbook, a special file where macros are stored so they can be used across all Excel workbooks. While this feature is convenient, there are times when you may need to delete the Personal Macro Workbook—maybe you no longer need certain macros, want to clear out outdated scripts, or are facing issues with macro execution.

But how do you remove it safely without causing any disruptions to Excel? In this guide, we'll walk you through the step-by-step process to delete macros from your Personal Macro Workbook and remove the Personal.xlsb file if necessary. We’ll also explore alternative methods, best practices, and solutions to common issues.

By the end of this guide, you’ll have complete control over your Excel macros, ensuring a clean and efficient workspace.?

What is the Personal Macro Workbook?

The Personal Macro Workbook (Personal.xlsb) is a hidden Excel file that stores macros you create or record so they can be used across all your workbooks. Unlike regular macros that are saved within individual Excel files, macros are in Personal.xlsb is available every time you open Excel, making it a powerful tool for automating repetitive tasks.

This workbook is automatically created the first time you record a macro using the Personal Macro Workbook storage option. However, since it is hidden by default, you won’t see it listed among your open Excel files. To view or edit the macros inside, you’ll need to unhide the Personal Macro Workbook by navigating to:

  1. Click on the View tab in Excel.
  2. Select Unhide from the Window group.
  3. Choose Personal.xlsb from the list and click OK.

While this feature is incredibly useful, sometimes you may need to delete or modify the Personal Macro Workbook. Maybe your macros are outdated, conflicting with new scripts, or you simply want a fresh start. In the following sections, we’ll explore how to delete personal macros in Excel and safely remove the Personal.xlsb file without affecting other Excel functionalities.

Reasons to Delete the Personal Macro Workbook?

There are several reasons why you might need to delete the Personal Macro Workbook (Personal.xlsb) in Excel. While it’s a convenient way to store macros for use across multiple workbooks, there are situations where removal becomes necessary:

1. Outdated or Redundant Macros

Over time, you may have recorded or written macros that are no longer needed. Instead of letting them clutter your Excel environment, deleting them can help keep your workspace clean and efficient.

2. Corruption Issues

If the Personal.xlsb file becomes corrupted, it may cause errors in Excel. In such cases, removing or replacing it can help restore smooth functionality.

3. Conflicting Macros

Sometimes, old macros interfere with newer ones or cause unintended automation. Deleting the Personal Macro Workbook ensures a fresh start.

4. Resetting or Cleaning the Macro Environment

If you want to delete personal macros in Excel and start from scratch, remove the Personal.xlsb file is the best approach.

How to Delete the Personal Macro Workbook (Step-by-Step)

If you want to delete the Personal Macro Workbook (Personal.xlsb), you can follow these step-by-step methods. Whether you’re looking to remove all macros or completely delete the file, these solutions will help you achieve a clean Excel environment.

Method 1: Delete Specific Macros from Personal.xlsb

If you only need to remove certain macros while keeping the Personal Macro Workbook, follow these steps:

  1. Open Excel and Access the Macro List by pressing ALT + F8 or go to Developer > Macros. A list of all macros, including those stored in Personal.xlsb, will appear.
  2. Select the Macro and choose the macro you want to remove. Then click Delete to remove it permanently.
  3. Save once you have removed the necessary macros, save your changes to ensure they are no longer available in Excel.

Method 2: Delete the Entire Personal.xlsb File

If you want to completely delete the Personal Macro Workbook, follow these steps:

  • Step 1. First, close Excel completely by ensuring Excel is not running before making changes.
  • Step 2. Navigate to the Excel Startup Folder by opening File Explorer and go to:

C:\Users\YourUsername\AppData\Roaming\Microsoft\Excel\XLSTART        

  • Step 3. You may need to enable hidden files by selecting View > Hidden Items in File Explorer.
  • Step 4.? Now, find the Personal.xlsb file in the XLSTART folder. Then, right-click and select Delete or press Shift + Delete to remove it permanently.
  • Step 5. Open Excel to confirm that the Personal Macro Workbook has been removed.
  • Step 6. Try creating a new macro to verify that Personal.xlsb is no longer active.

Alternative: Move PERSONAL.XLSB Instead of Deleting

If you’re unsure about completely deleting the file, you can move it to another location instead. Simply cut and paste the Personal.xlsb file into a backup folder. This way, you can restore it if needed.

With these steps, you can successfully delete macros from the Personal Macro Workbook or remove the workbook entirely. Next, let’s explore additional methods and troubleshooting solutions.

Alternative Methods to Remove the Personal Macro Workbook

If the standard methods didn’t work or you’re looking for other ways to delete the Personal Macro Workbook (Personal.xlsb), here are some alternative approaches.

Method 1: Delete PERSONAL.XLSB Using VBA

If you prefer a programmatic approach, you can use VBA (Visual Basic for Applications) to remove the Personal.xlsb file.

Step 1. To open the VBA Editor, press ALT + F11 to open the VBA Editor. the Immediate Window (if not visible, press CTRL + G), type the following command, and then press enter to execute the command:

Kill Environ("AppData") & "\Microsoft\Excel\XLSTART\PERSONAL.XLSB"        

Step 2. Now, close and Restart the Excel.

Method 2: Remove Personal.xlsb from Excel Options

Excel allows you to control startup files, including the Personal Macro Workbook.

  • Step 1. Open Excel and click File > Options.
  • Step 2. Select Advanced from the left panel.
  • Step 3. Disable XLSTART Folder Macros and scroll down to the General section.
  • Step 4. Locate At startup, open all files in, and clear any listed paths.
  • Step 5. Click OK and restart Excel.

Method 3: Use Safe Mode to Delete the File

If Excel locks the Personal.xlsb file, you may need to delete it in Safe Mode.

Step 1. Close Excel and Open Safe Mode

Step 2. Press Windows + R, type Excel/safe and hit Enter.

Step 3. Follow the steps in Method 2 to delete Personal.xlsb from the XLSTART folder.

Step 4. Restart Excel in Normal Mode

Step 5. Once deleted, restart Excel normally to confirm the removal.

These alternative methods provide additional ways to delete macros from the Personal Macro Workbook if standard options fail.

Troubleshooting Issues When Deleting the Personal Macro Workbook

Sometimes, you might encounter issues while trying to delete the Personal Macro Workbook (Personal.xlsb). If the file doesn’t delete or Excel keeps recreating it, here are some troubleshooting steps to help.

Issue 1: PERSONAL.XLSB is Still in Use

Problem: Excel says the file is open or in use. Solution:

  1. Close Excel Completely – Ensure no Excel processes are running. Open Task Manager (CTRL + SHIFT + ESC), find Excel.exe, and click End Task.
  2. Try Deleting Again – Navigate to

C:\Users\YourUsername\AppData\Roaming\Microsoft\Excel\XLSTART         

Afterthat, delete Personal.xlsb.

Issue 2: The File Keeps Reappearing

Problem: After deleting Personal.xlsb, Excel recreates it. Solution:

  1. Check for AutoSave or Backup Features – If your system has a backup system, ensure it’s not restoring the file.
  2. Disable Excel Startup Files – Go to File > Options > Advanced and remove startup folder paths under "At startup, open all files in".
  3. Manually Remove Macros – Open the VBA Editor (ALT + F11), expand the Modules section, delete any existing macros, and save changes.

Issue 3: Permission Denied When Deleting

Problem: You get an error saying “You don’t have permission to delete this file.” Solution:

  1. Run File Explorer as Administrator – Right-click File Explorer, select Run as Administrator, then try deleting Personal.xlsb.
  2. Use Safe Mode – Restart Excel in Safe Mode (excel /safe in the Run dialog) and delete the file.

By following these troubleshooting steps, you can successfully remove Personal.xlsb without Excel restoring it.

If your Personal.xlsb file is password-protected, you may need to remove VBA project password from Excel before deleting or editing it. Here you can prefer to opt for SysTools VBA password recovery software. This software can easily recover password from Excel and protects macros using VBA project encryption, making it difficult to access or modify them without the correct password.

Watch the Full Guide Video of How this Software Works

How to Prevent Personal.xlsb from Being Recreated

Once you’ve successfully deleted the Personal Macro Workbook (Personal.xlsb), you might want to ensure that it doesn't get recreated in the future. Excel is designed to automatically generate the Personal.xlsb file whenever you record a macro and save it to the Personal Macro Workbook. Here’s how to prevent it from appearing again.

1. Avoid Saving Macros to the Personal Macro Workbook

By default, Excel suggests saving macros to Personal.xlsb for reuse across workbooks. To prevent this:

  • Disable Personal Macro Workbook Option – When recording a new macro, instead of selecting Personal Macro Workbook, choose This Workbook or New Workbook. This will ensure the macro is saved within the specific workbook instead of being stored in Personal.xlsb.

2. Remove or Disable Excel Add-Ins

Excel add-ins can also prompt Excel to recreate Personal.xlsb. Check for any add-ins that might be causing this:

  • Go to File > Options > Add-ins
  • Look for any add-ins that might interact with the Personal Macro Workbook and disable them temporarily.

3. Clear Excel’s Startup Folder

The XLSTART folder is where Excel looks for files to open on startup, including Personal.xlsb. To prevent it from being automatically opened:

  • Open File Explorer and go to the XLSTART folder (usually located in

C:\Users\YourUsername\AppData\Roaming\Microsoft\Excel\XLSTART)        

  • Delete or move the Personal.xlsb file from this folder to another location.

4. Turn Off Excel’s Auto-Recuperation Feature

If Excel crashes, it may attempt to restore files, including the Personal Macro Workbook. To avoid this:

  • Go to File > Options > Save.
  • Disable AutoRecover or configure it to avoid automatically opening and saving files to the XLSTART folder.

By following these steps, you can prevent Excel from recreating Personal.xlsb and ensure that your workspace stays clean and organized.

Conclusion

In conclusion, managing and deleting the Personal Macro Workbook (Personal.xlsb) can help streamline your Excel environment and keep things organized. Whether you're simply looking to delete macros, prevent the automatic creation of Personal.xlsb, or remove a password-protected file, the steps outlined in this blog will help you handle the task with ease.

It’s important to remember that Personal.xlsb serves as a central location for macros you want to reuse across different workbooks. However, if you no longer need it, or if it's becoming cumbersome, deleting the file is a great way to clean up your workspace. By following the right steps, you can delete, protect, or prevent its recreation, making sure that Excel operates smoothly without unnecessary clutter.

Frequently Asked Questions

Q. How do I delete the Personal Macro Workbook?

To delete the Personal.xlsb file:

  • Navigate to the XLSTART folder (usually located at C:\Users\YourUsername\AppData\Roaming\Microsoft\Excel\XLSTART).
  • Delete Personal.xlsb from this folder.
  • Restart Excel to confirm the deletion.

Q. Why does my Personal Macro Workbook keep reappearing?

This usually happens because Excel automatically creates Personal.xlsb whenever you record a macro and choose to save it to the Personal Macro Workbook. You can prevent it from reappearing by ensuring macros are not saved to Personal.xlsb in the future and removing the file from the XLSTART folder.

Q. How do I access my Personal Macro Workbook if it’s password-protected?

If your Personal.xlsb is locked, you can use a VBA password remover tool like SysTools VBA Password Remover to unlock it. This tool will allow you to access and remove macros without needing a password.

Q. Is there any risk in deleting the Personal Macro Workbook?

No, deleting Personal.xlsb will only remove the macros stored in that file. Your regular workbooks and Excel functions will not be affected. However, be sure to back up any important macros before deletion.

要查看或添加评论,请登录

SysTools的更多文章

社区洞察

其他会员也浏览了