Skip to main content
How-To Guide

How to Load and Run a LISP File in AutoCAD

Published September 2026  |  74mph Solutions

A LISP routine is a small program, saved as a .lsp file, that adds a new command to AutoCAD. Loading it tells AutoCAD the command exists. Running it is then just a matter of typing that command. This guide covers both, how to make a routine load every time AutoCAD starts, the errors people hit most, and how to run a routine on hundreds of drawings at once.

Quick answer

  1. Type APPLOAD and press Enter.
  2. Browse to your .lsp file, select it, and click Load, then Close.
  3. Type the routine's command name (for example DELBLOCK) and press Enter.

On this page: 3 ways to load a LISP · Run it (find the command name) · Load it automatically · Security warnings · AutoCAD LT · Common errors · Run it on many drawings

3 ways to load a LISP file

1. APPLOAD (the standard way)

  1. Type APPLOAD, or go to the Manage tab and click Load Application.
  2. Find the .lsp file, select it, and click Load. The message at the bottom of the dialog confirms it loaded.
  3. Click Close.

2. Drag and drop

Drag the .lsp file from File Explorer and drop it on the drawing area. AutoCAD loads it straight away. This is the fastest way to try a routine once.

3. Type (load) at the command line

Type the full path in a (load) expression. Use forward slashes, or double every backslash:

(load "C:/CAD/Lisp/MyRoutine.lsp")
(load "C:\\CAD\\Lisp\\MyRoutine.lsp")

If the folder is on AutoCAD's support file search path, the file name alone is enough: (load "MyRoutine.lsp"). This form also works inside scripts and menus, which is what makes it useful for batch work.

Run the routine: find its command name

Loading a routine does not run it. Type the command it defines. The command name is not always the file name, so if typing the file name gives "Unknown command", open the .lsp file in Notepad and look for a line like this:

(defun c:DELBLOCK ( / name ss) ...

Whatever follows c: is the command, here DELBLOCK. A file can define several commands, so check every defun c: line. Some routines also run on their own as soon as they load, or print their command names when they do.

Load a LISP automatically every time

Startup Suite (easiest)

  1. Type APPLOAD.
  2. In the Startup Suite area, click Contents.
  3. Click Add, pick the .lsp file, then Close both dialogs.

The routine now loads in every drawing you open.

acaddoc.lsp (for CAD managers)

Put (load "MyRoutine.lsp") lines in a file named acaddoc.lsp in a folder on the support file search path. AutoCAD loads acaddoc.lsp into every drawing, so one shared file can load the same routines for a whole office. acad.lsp works the same way but, by default, loads only once per session; the ACADLSPASDOC system variable changes that.

"Security: Unsigned Executable File" warnings

Since AutoCAD 2014, loading a routine from a folder AutoCAD does not trust shows a security warning. The SECURELOAD system variable controls this:

SECURELOADWhat happens
0Loads from anywhere with no warning (not recommended)
1Warns before loading from a folder outside the trusted locations (the default)
2Loads only from trusted locations

The right fix is to add the folder that holds your routines to the trusted locations: type OPTIONS, open the Files tab, expand Trusted Locations, and add the folder. The warning matters most for batch work, because a dialog waiting for a click stops an unattended run.

Can AutoCAD LT load LISP?

AutoCAD LT 2024 and later: yes. Load routines the same way as in full AutoCAD. AutoCAD LT 2023 and earlier: no, LT did not run AutoLISP before 2024. Even in LT 2024 and later, routines that use the vla- and vlax- (ActiveX) functions will not work, because LT does not support them.

Common errors and what they mean

You seeWhat it means
Unknown commandThe routine is not loaded, or you typed the file name instead of the command name. See find the command name.
; error: LOAD failedAutoCAD cannot find the file. Check the path, use forward slashes, or put the folder on the support file search path.
; error: no function definition: VLAX-...The routine uses ActiveX functions. Add (vl-load-com) at the top of the routine, or, in AutoCAD LT, it cannot run.
Security warning on every loadThe folder is not a trusted location. See security warnings.

Run a LISP routine on hundreds of drawings

APPLOAD and the Startup Suite load a routine into the drawings you open yourself. To run it on a whole project folder, you need something that opens each drawing in turn. Hurricane does exactly that: it runs the same script on every drawing in a list, opening, running, saving and closing each one, unattended.

The script just loads the routine and calls it:

(load "MyRoutine.lsp")
MYROUTINE

If the routine asks questions, put each answer on its own line after the command, exactly as you would type it. For a worked example, see How to Delete a Block in AutoCAD, which uses a routine like this to remove a block from every drawing in a folder.

Run Your LISP Routines on Every Drawing

Hurricane runs your script and LISP routines across hundreds of DWG files, unattended.

Download Free Trial Buy Now

Related: How to Delete a Block in AutoCAD  |  AutoCAD Script Comments  |  AutoCAD Commands List  |  AutoCAD System Variables List