# xarray.CFTimeIndex.fillna

#### CFTimeIndex.fillna(value)[[source]](https://github.com/pydata/xarray/blob/main/xarray/../.pixi/envs/doc/lib/python3.14/site-packages/pandas/core/indexes/base.py#L2743-L2778)

Fill NA/NaN values with the specified value.

* **Parameters:**
  **value** ([scalar](../user-guide/terminology.html.md#term-scalar)) – Scalar value to use to fill holes (e.g. 0).
  This value cannot be a list-likes.
* **Returns:**
  [`Index`](https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.Index.html#pandas.Index) – NA/NaN values replaced with value.

#### SEE ALSO
`DataFrame.fillna`
: Fill NaN values of a DataFrame.

`Series.fillna`
: Fill NaN Values of a Series.

### Examples

<div class="try_examples_button_container"><button class="try_examples_button" onclick="window.tryExamplesShowIframe('bbc6617e-cf8e-47ee-ab14-9115ad896690','db17be07-5683-431d-ae3d-50bb8001d3e2','d135a00b-0fcc-49a6-a6ec-44b37d5716ab','../lite/tree/../notebooks/index.html?path=2e7fa477_7d65_4038_95db_9c36899f00b3.ipynb','None')">Try it in your browser!</button></div>
```pycon
>>> idx = pd.Index([np.nan, np.nan, 3])
>>> idx.fillna(0)
Index([0.0, 0.0, 3.0], dtype='float64')
```

<div id="d135a00b-0fcc-49a6-a6ec-44b37d5716ab" class="try_examples_outer_iframe  hidden"><div class="try_examples_button_container"><button class="try_examples_button" onclick="window.tryExamplesHideIframe('bbc6617e-cf8e-47ee-ab14-9115ad896690','d135a00b-0fcc-49a6-a6ec-44b37d5716ab')">Go Back</button><button class="try_examples_button" onclick="window.openInNewTab('bbc6617e-cf8e-47ee-ab14-9115ad896690','d135a00b-0fcc-49a6-a6ec-44b37d5716ab')">Open In Tab</button></div><div id="db17be07-5683-431d-ae3d-50bb8001d3e2" class="jupyterlite_sphinx_iframe_container"></div></div><script>document.addEventListener("DOMContentLoaded", function() {window.loadTryExamplesConfig("../try_examples.json");});</script>
