TOP

Forex Function

FOREX() Description

The FOREX() function is designed for automatic retrieval of international currency exchange rates directly from the Yahoo Finance website (finance.yahoo.com) for the specified currency pair (e.g., EURUSD, USDJPY) and selected date. It supports both historical quotes and current real-time values.

This function is convenient for creating stock trackers in tables Excel (LibreOffice Calc) and will be useful for investors, traders, and financial analysts.


This function requires an internet connection to work.

Key Features of the FOREX Function

Syntax:

=FOREX(Pair; [Date]; [Indicator])

Parameters:

Example Usage

Example 1

The FOREX() function is easy to use. You just need to specify the cell with the currency pair code and Excel (Calc) will automatically import the exchange rate of these currencies for the specified date:

=FOREX(Pair; Date)

We will get the following result:

Example of using the FOREX() function
Example of using the FOREX() function

This example uses the following values:

Example 2

Example of using the FOREX() function
Example of using the FOREX() function

This example uses the following values:

Corresponding data from the Yahoo Finance website:

FOREX formula usage

How It Works?

The FOREX() function can work in normal mode as well as an array function.

To use it as an array, simply enter the function into any cell, specifying the appropriate parameters. After that, you need to press Ctrl+Shift+Enter to enter the array formula and LO Calc will automatically return a table with data.

To select all cells associated with the array formula, simply select any array cell and press Ctrl+/.

If you need to convert an array formula to values - select the entire array and in the menu Data > Calculate select Formula to Value.

When using a date as text, it must first be converted into a real date, for example: DATEVALUE("2026-01-25").


If you need to obtain historical data for a long period of time, we recommend using the function YFINANCE to avoid delays.

Ready-made Templates

You can also use ready-made templates to retrieve historical data, financial indicators, or a company profile.

To do this, go to the menu YLC Utilities > Template > Company screener and choose one of the following reports:

Download Extension

You can use the function FOREX() by installing the extension YLC Utilities.

After that, this function will be available in all files opened in Excel (LibreOffice Calc).


This function is available in the following extensions: YLC FunctionsYLC Utilities

The YLC Utilities menu in LO Calc

The YLC Utilities menu in LO Calc

The YLC Utilities menu in Excel

The YLC Utilities menu in Excel