Simple example to place order from Microsoft Excel

If you are new to API Trading, then please check out this article ‘Why we need Trade API in short?’ and watch our video’s to know more about API Trading.

This article is meant for developers/programmers, if you are a normal retail trader, then check out our Bridge article.

You can use our DotNet libraries to build trading platforms and systems in Excel. VBA knowledge is must to build trading system in Excel and manage orders/positions from Excel. If you don’t know VBA, then you can hire a VBA programmer to build your system in Excel.

If you are a Zerodha user, then refer this page for complete list of functions supported by our DotNet libraries.

If you are a Upstox user, refer this page.

In cell A1, You have some formula that will display “BUY” on certain conditions and you want to place a BUY order in AXISBANK with 150 Qty when cell A1 display “BUY”.

In cell A2
The above formula will call the PlaceSimpleOrder function when cell A1 display “BUY” and places a Simple Order to Upstox OMS through API and returns the order id in the excel cell.

Here the PlaceSimpleOrder is a UDF which wraps the PlaceOrder function of the UpstoxNet.dll. In our sample excel workbook, we have wrapped all the functions of UpstoxNet.dll as UDF, so that you can call those functions from within excel cell.

If you are new to Algo Trading, then try exploring the strategies at We already have some famous strategies coded in VBA/AFL (like ORB, Levels Breakout, Supertrend etc). You can use these strategies to get started quickly or use as a reference to build your own strategy. We will periodically add new strategies and codes that are available in public domain.

Was this article helpful?

Related Articles

Leave A Comment?