ql.html)
    * [ pandas.read_gbq ](pandas.read_gbq.html)
    * [ pandas.read_stata ](pandas.read_stata.html)
    * [ pandas.DataFrame.to_stata ](pandas.DataFrame.to_stata.html)
    * [ pandas.io.stata.StataReader.data_label ](pandas.io.stata.StataReader.data_label.html)
    * [ pandas.io.stata.StataReader.value_labels ](pandas.io.stata.StataReader.value_labels.html)
    * [ pandas.io.stata.StataReader.variable_labels ](pandas.io.stata.StataReader.variable_labels.html)
    * [ pandas.io.stata.StataWriter.write_file ](pandas.io.stata.StataWriter.write_file.html)
  * [ General functions ](../general_functions.html)
  * [ Series ](../series.html)
  * [ DataFrame ](../frame.html)
  * [ pandas arrays, scalars, and data types ](../arrays.html)
  * [ Index objects ](../indexing.html)
  * [ Date offsets ](../offset_frequency.html)
  * [ Window ](../window.html)
  * [ GroupBy ](../groupby.html)
  * [ Resampling ](../resampling.html)
  * [ Style ](../style.html)
  * [ Plotting ](../plotting.html)
  * [ Options and settings ](../options.html)
  * [ Extensions ](../extensions.html)
  * [ Testing ](../testing.html)
  * [ Missing values ](../missing_value.html)

  * [ __ ](../../index.html)
  * [ API reference ](../index.html)
  * [ Input/output ](../io.html)
  * pandas.DataF... 

#  pandas.DataFrame.to_parquet  #

DataFrame.  to_parquet  (  _ path  =  None  _ , _ *  _ , _ engine  =  'auto'
_ , _ compression  =  'snappy'  _ , _ index  =  None  _ , _ partition_cols  =
None  _ , _ storage_options  =  None  _ , _ **  kwargs  _ )  [ [source]
](https://github.com/pandas-
dev/pandas/blob/v2.2.2/pandas/core/frame.py#L3018-L3122) #

    

Write a DataFrame to the binary parquet format.

This function writes the dataframe as a [ parquet file
](https://parquet.apache.org/) . You can choose different parquet backends,
and have the option of compression. See [ the user guide
](../../user_guide/io.html#io-parquet) for more details.

Parameters  :

    

**path** str, path object, file-like object, or None, default None

    

String, path object (implementing ` os.PathLike[str]  ` ), or file-like object
implementing a binary ` write()  ` function. If None, the result is returned
as bytes. If a string or path, it will be used as Root Directory path when
writing a partitioned dataset.

**engine** {âautoâ, âpyarrowâ, âfastparquetâ}, default âautoâ

    

Parquet library to use. If âautoâ, then the option ` io.parquet.engine  `
is used. The default ` io.parquet.engine  ` behavior is to try âpyarrowâ,
falling back to âfastparquetâ if âpyarrowâ is unavailable.

**compression** str or None, default âsnappyâ

    

Name of the compression to use. Use ` None  ` for no compression. Supported
options: âsnappyâ, âgzipâ, âbrotliâ, âlz4â, âzstdâ.

**index** bool, default None

    

If ` True  ` , include the dataframeâs index(es) in the file output. If `
False  ` , they will not be written to the file. If ` None  ` , similar to `
True  ` the dataframeâs index(es) will be saved. However, instead of being
saved as values, the RangeIndex will be stored as a range in the metadata so
it doesnât require much space and is faster. Other indexes will be included
as columns in the file output.

**partition_cols** list, optional, default None

    

Column names by which to partition the dataset. Columns are partitioned in the
order they are given. Must be None if path is not a string.

**storage_options** dict, optional

    

Extra options that make sense for a particular storage connection, e.g. host,
port, username, password, etc. For HTTP(S) URLs the key-value pairs are
forwarded to ` urllib.request.Request  ` as header options. For other URLs
(e.g. starting with âs3://â, and âgcs://â) the key-value pairs are
forwarded to ` fsspec.open  ` . Please see ` fsspec  ` and ` urllib  ` for
more details, and for more examples on storage options refer [ here
](https://pandas.pydata.org/docs/user_guide/io.html?hig