Luau
Implementing functions in Luau
xllify lets you create high-performance Excel custom functions using Luau.
An incredibly easy language to learn, it boasts strong numerical performance and is used in Roblox and other well-known games. It therefore has millions of end users!
With xllify, your Luau code compiles to bytecode and runs directly in Excel's process at near-C speeds with full multithreaded recalculation support.
Despite being dominant for games and web server configuration, Lua(u) it is less widely used than Python in the data space. However, we encourage you to check out Luau as a starting point if your functions can be expressed as pure computations. It is simple and very fast.
What you need
Your Luau functions in a .luau file
The xllify CLI and optionally xllify-lua
Typical workflow
Define functions using xllify.fn(metadata, fn) calls.
Run the CLI to produce an XLL:
xllify awesome_lua.xll my_functions.luauLoad the generated XLL into Excel by double clicking on it
Call the custom functions from Excel like any other worksheet function.
More on building XLLs
Use the xllify CLI to build XLLs:
# Single script
xllify MyAddin.xll my_functions.luau
# Multiple scripts
xllify MyAddin.xll math.luau text.luau utils.luau
# Mix Luau and Python in a single add-in
xllify MyAddin.xll calculations.luau api_calls.py \
--py-entrypoint api_calls \
--py-requirements requirements.txtDevelopment workflow
Edit your .luau file
Close Excel
Rebuild XLL
xllify MyAddin.xll my_functions.luauReopen Excel
Troubleshooting
Last updated