applies pitch shifting to audio by the ratio r, shifting every frequency to .

Details and Options

  • AudioPitchShift shifts the pitch of the input audio signal without affecting the duration.
  • The frequency ratio r can be given as a pitch interval, including:
  • Quantity[oct,"octaves"]correspond to
    Quantity[sem,"semitones"]correspond to
  • AudioPitchShift takes a PartitionGranularity option that controls the partitioning of audio, used for the computation of the short-time Fourier transform.
  • By default, a phase vocoder algorithm is used. Select Method->"Speech" to use an algorithm tailored for speech signals. In this case, while the fundamental frequency is changed, the formants of the signal are not modified.


open allclose all

Basic Examples  (2)

Shift the audio pitch by a factor of two:

Shift the audio pitch by a semitone:

Scope  (3)

A shift by n octaves corresponds to a frequency ratio of 2n:

A shift by s semitones corresponds to a frequency ratio of 2s/12:

AudioPitchShift can be used to change the pitch of a harmonically complex sound without altering its timbre and timing:

The frequency ratio between the components of the audio signal is not changed:

Options  (4)

Method  (1)

Use Method->"Speech" for speech signals to shift the pitch while maintaining other voice characteristics:

Compare with the normal pitch shifting, which dramatically affects the timbre of the voice:

PartitionGranularity  (3)

Using a bigger partition size will improve the frequency response but will smear the transient components:

Using a small offset value will in general increase the quality of the result at the cost of more computation time:

If only the partition size is specified, the offset is calculated as 25% of the partition size.

Use a different window shape to change the quality of the result:

By default, HannWindow is used.

Applications  (1)

Shift the pitch of an audio object to match a target frequency:

Extract the mean frequency with AudioLocalMeasurements:

Shift the audio to reach the target frequency:

Properties & Relations  (2)

AudioPitchShift and AudioFrequencyShift modify the spectrum of the signal in different ways:

AudioPitchShift shifts each frequency f in the signal by an amount proportional to the frequency itself (f'=f×shift), thus preserving the timbre in the shifted signal:

AudioFrequencyShift shifts every frequency f by the same amount (f'=f+shift), changing dramatically the timbre in the shifted signal:

Change the pitch of a recording by using a different sample rate:

AudioPitchShift changes the pitch without altering the timing:

Possible Issues  (2)

The quality of the result degrades with large shift parameters:

Using Method->"Speech" for non-speech signals may not sound as expected:

Wolfram Research (2016), AudioPitchShift, Wolfram Language function, (updated 2020).


Wolfram Research (2016), AudioPitchShift, Wolfram Language function, (updated 2020).


Wolfram Language. 2016. "AudioPitchShift." Wolfram Language & System Documentation Center. Wolfram Research. Last Modified 2020.


Wolfram Language. (2016). AudioPitchShift. Wolfram Language & System Documentation Center. Retrieved from


@misc{reference.wolfram_2021_audiopitchshift, author="Wolfram Research", title="{AudioPitchShift}", year="2020", howpublished="\url{}", note=[Accessed: 17-January-2022 ]}


@online{reference.wolfram_2021_audiopitchshift, organization={Wolfram Research}, title={AudioPitchShift}, year={2020}, url={}, note=[Accessed: 17-January-2022 ]}