### Navigation

- index
- modules |
- next |
- previous |
- home|
- examples|
- tutorials|
- pyplot|
- docs »
- The Matplotlib API »
- matplotlib.pyplot »

# matplotlib.pyplot.gca

`matplotlib.pyplot.``gca`(**kwargs)

  Get the current `Axes` instance on the current figure matching the given keyword args, or create one.

  See also

  `matplotlib.figure.Figure.gca`
    The figure’s gca method.

  Examples

  To get the current polar axes on the current figure:

      plt.gca(projection='polar')

  If the current axes doesn’t exist, or isn’t a polar one, the appropriate axes will be created and then returned.

## Examples using `matplotlib.pyplot.gca`

Custom scale

Simple Anchored Artists

Trifinder Event Demo

Contour Demo

Contour Image

Tricontour Demo

Tricontour Smooth Delaunay

Tricontour Smooth User

Tripcolor Demo

Triplot Demo

Manual Contour

Anchored Artists

Anscombe’s Quartet

Arrow Demo

Interactive functions

Logo

Multiple Figs Demo

Set And Get

Symlog Demo

Usetex Fonteffects

Pyplot Scales

Hinton diagrams

Mathtext Examples

Rainbow text

Precise text layout

Text Rotation Relative To Line

Usetex Demo

Pyplot tutorial

Legend guide

Tight Layout guide