XPSfit – How To Start

A guide for first-time users · XPSfit 0.9.1

XPSfit fits XPS spectra automatically: it proposes the chemical states, fits them, and tells you in plain words when the data or the fit has a problem. This guide takes a first-time user from installation to a finished, exported fit.

1. Installing and starting

Install once with the Setup file, then start XPSfit from its icon; it opens in your web browser and runs only on your own computer.

  1. Install: double-click XPSfit-Setup-<version>.exe. No administrator password and no internet are needed. If Windows shows "Windows protected your PC", click More info → Run anyway.
  2. Start: double-click the XPSfit icon on the desktop or in the Start menu. Your browser opens the XPSfit page. Nothing is sent over the internet.
  3. Stop: click Quit at the top right. Closing the browser tab alone leaves XPSfit running in the background; double-clicking the icon again brings the same session back.
  4. Update: run a newer Setup file over the old one. Your settings are kept.

Your library additions, templates, reference spectra and settings are kept in the XPSFitter folder in your user folder (C:\Users\<you>\XPSFitter). If something goes wrong, send the file xpsfitter.log from that folder with a description of what you were doing.

2. The screen at a glance

Everything for fitting one spectrum is on the Fit tab; the numbers match the labelled screenshot below.

No.PartWhat it does
1Top barOpen files (VAMAS .vms, CSV or text), Load demo data to practise, Export all results (CSV), Clear, Quit.
2SidebarYour samples and their spectra. Drag files onto the dashed box to open them. The coloured dot shows the quality grade of each spectrum.
3TabsFit, Sample report, Auto fit fixed, Batch, References, Library, Help (section 4).
4Fit rangeFirst and last binding energy used for the fit. Change them and click Apply; Full range goes back to the whole spectrum (section 6).
5Elements in this sampleType the elements present (e.g. Ni, Se, C, O, N) so the auto-fit only considers overlaps from these.
6Fit withTick what the fit may use: core levels, satellites, Auger lines.
7Fit controlsCore level, background (Shirley, Tougaard, Linear), Auto-fit, Prev/Next through earlier fits, Refit with my changes, Remove spikes, Save as template, Export (figure or table).
8GraphData (circles), background (grey), components (coloured), envelope (black) and the residual underneath.
9Components tableBelow the graph: one row per component (section 5).
10Data quality and notesBelow the table: green/amber/red checks and notes on ambiguous assignments (section 8).
11Bottom barVersion number and how to acknowledge XPSfit.
The Fit tab with its parts numbered 1 to 11
The Fit tab, with the NiSe Ni 2p spectrum fitted between 846 and 866.5 eV. Red numbers match the table above.

3. Fitting a spectrum, step by step

Most fits take seven steps; a red grade sends you back to step 4 rather than on to export.

From file to finished fit in seven steps 1 Open files 2 Check columns 3 Charge-correct 4 Range, elements 5 Auto-fit 6 Refine 7 Export VAMAS, CSV or text energy, intensity, hν Sample report: C 1s top of the Fit tab proposes and fits drag, edit, Refit figure and table ok red: change range, background, elements or spikes Grade?
XPSfit workflow · 7 steps, 1 decision
  1. Open files. VAMAS (.vms) exports from ESCApe or CasaXPS are best. For CSV or text files a window, Check how this file was read, asks which column holds the energy (binding or kinetic), which holds the intensity, and the X-ray energy (Al Kα 1486.6 eV unless you change it).
  2. Check the columns in that window before clicking OK. A wrong column is the most common reason for a fit that makes no sense.
  3. Charge-correct on the Sample report tab: Set from C 1s shifts every region of that sample so adventitious carbon sits at 284.8 eV.
  4. Fit range and elements at the top of the Fit tab: narrow the range when the spectrum needs it (sections 6 and 7) and list the elements in the sample.
  5. Auto-fit. XPSfit tries the chemical states in its library and keeps only components that the data clearly support.
  6. Refine. Read the grade and the notes, then adjust peaks in the table or on the graph and click Refit with my changes. Prev/Next step between your fits.
  7. Export the figure (PNG, SVG, PDF) and the table (CSV) from the Export menu.

4. The tabs

You do most work on the Fit tab; the other six tabs handle the sample as a whole, fixed models, series, standards and the library.

TabUse it to
FitFit one spectrum: fit range, elements, auto-fit, the graph, the components table, quality checks and notes.
Sample reportCharge correction (Set from C 1s, or type a shift), the X-ray source (photon energy, monochromated or not), the expected elements, sample-level checks (charging, unexpected survey peaks), composition in atomic % and the Auger parameter.
Auto fit fixedChoose exactly which components to use. Leave a value empty to fit it or type a number to fix it; optionally share one FWHM and keep the spin-orbit splitting at the library value. Fit one spectrum or all spectra of that core level.
BatchFit many spectra at once, automatically or with a saved template, so every sample gets the same model and comparisons are fair.
ReferencesSave measured standards (e.g. Ni metal, NiO, Ni(OH)₂) and fit an unknown as a mixture of them. This is the most reliable way to get oxidation-state fractions for Ni, Co, Fe, Mn and Cu 2p.
LibraryLook up and edit core levels and chemical states. What is this peak? lists photoelectron and Auger lines near any binding energy. Add a missing core level or state, and enter Kratos sensitivity factors (RSF) for atomic %.
HelpA short version of this guide and good-practice notes.

5. Components table and mouse controls

Every component can be changed in the table or by dragging it on the graph; the curve redraws at once, and Refit with my changes then optimises from your values.

The components table (below the graph) has one row per component:

ColumnMeaning
ComponentChemical state, e.g. Ni²⁺ (NiO / Ni(OH)₂). Satellites and peaks from other elements are marked.
Position (eV)Peak position of the lower-BE line. Tick the box beside it to lock the value during refits.
FWHM (eV)Width. Lock it with its box, or tick share to give all components of the core level one width.
AreaFitted area; it can also be locked.
Spin-orbit (eV)Splitting of a doublet (e.g. 4f, 3d, 2p). Locked at the library value by default; untick to let it vary by ±0.5 eV.
ShapeLine shape: SGL (default, 30 % Lorentzian), GL, or DS for asymmetric metallic peaks.
%Share of this core level's area. Satellites and peaks of other elements are not counted.
✕ DeleteRemoves the component.

Under the table, Add component offers every line that falls in the fit range: the core level's own states first, then elements of this sample, then other elements, Auger lines and minor lines. Type an element (e.g. Se) in the small box to list only its lines.

On the graph:

Three ways to reshape a peak with the mouse Round handle: position and height Square handle: width (FWHM) Square handle: width (FWHM) Drag the peak itself: position only
Peak handles on the graph · click a peak first to select it

6. Fit range: fitting a spectrum in sections (Ni 2p)

When a single background cannot span the whole spectrum, fit it in sections: for Ni 2p, fit 2p₃/₂ from 846 to 866.5 eV, and 2p₁/₂ separately if you need it.

Why it is needed. A Shirley background runs from the intensity at the low-BE end to the intensity at the high-BE end, rising in step with the peak area in between. Both ends must sit on flat, peak-free parts of the spectrum. A Ni 2p scan from 840 to 890 eV ends inside the 2p₁/₂ satellite structure, so the background climbs too high: in the NiSe nanoparticle example below it rises 0.13 above the data at 865 eV. The intensity left over is negative there, and no set of peaks can fit it. Reduced χ² was 26 for the whole window.

Ni 2p fitted over the whole 840–890 eV window: the background sits above the data around 865 eV
Before: one background over 840–890 eV. Between 860 and 868 eV the grey background and the fit lie above the data points, so the fit cannot work.

How to fit 2p₃/₂ on its own:

  1. Open the spectrum and look at it on the Fit tab.
  2. In Fit range (BE), set the low end on the flat part 5–7 eV below the main peak (846 eV for Ni).
  3. Set the high end at the lowest point of the valley between the 2p₃/₂ satellites and the 2p₁/₂ peak (866.5 eV here).
  4. Click Apply, then Auto-fit. The graph now shows only that range, and the background ends at your two energies.
  5. If you also need 2p₁/₂, fit it as a separate step from the same valley to the flat region above its satellite (about 866.5–890 eV for Ni).
Ni 2p3/2 fitted between 846 and 866.5 eV: the background stays below the data
After: fit range 846–866.5 eV. The background ends in the valley and stays below the data everywhere. XPSfit's library calls the 852.8 eV component "Ni⁰ (metallic)" because Ni metal and NiSe sit at almost the same energy; rename it Ni–Se in your report.

Result for the NiSe nanoparticles (846–866.5 eV): the background stays below the data and reduced χ² falls from 26 to about 2–5, depending on the model.

ComponentBE (eV)FWHM (eV)Share of Ni 2p₃/₂ area
Ni–Se (NiSe)852.851.139 %
Ni²⁺ (Ni–O / Ni–OH, surface oxidation)855.62.742 %
Satellite858.5about 3.910 %
Satellite861.42.78 %

The Ni–Se peak needs a more Lorentzian or asymmetric shape (choose DS in the Shape column); a symmetric peak leaves a misfit at 850–852 eV. Count the satellites with Ni²⁺ when you report the oxidised fraction. Values are from normalised (0–1) data, so fit raw counts for publication.

Tips

7. Other spectra that need a narrower range

Narrow the range whenever an end of the window does not sit on a flat, peak-free part of the spectrum; split into sections only when the two spin-orbit lines are separated by a clear valley.

The energies below are typical values to start from. Always check where the flat regions and valleys are in your data, and move the range ends there.

SpectrumWhat to fitWhy
Ni 2p2p₃/₂ with its satellites, about 846–866.5 eV; 2p₁/₂ separatelyStrong satellites; the scan's high-BE end lies inside the 2p₁/₂ satellites (section 6).
Co 2p2p₃/₂ with its satellites, about 775–794 eVSame as Ni: Co²⁺ satellites fill the region up to 2p₁/₂.
Cu 2p2p₃/₂ with the Cu²⁺ shake-up, about 928–948 eVThe shake-up satellites at 940–945 eV belong in the fit; 2p₁/₂ (about 952 eV) can be left out.
Mn 2p2p₃/₂, about 636–650 eVMultiplet splitting broadens each line; the 2p₁/₂ region adds little.
Fe 2pUsually the whole 2p region, not split2p₁/₂ (about 723–725 eV) sits right next to the 2p₃/₂ satellites (about 719 eV), so there is no clean valley. Prefer the Tougaard background or References (standards).
Zn 2p, Ba 3dOne line, e.g. Zn 2p₃/₂ about 1015–1030 eVVery large spin-orbit splitting (Zn 23 eV, Ba 15 eV): the two lines are separate peaks with a long, often noisy gap.
Ce 3d, La 3d and other rare earthsThe whole 3d region, not splitSatellites of 3d₅/₂ overlap 3d₃/₂. Use Tougaard or reference spectra.
Metals with plasmon losses (Al 2p, Mg 2p, Si 2p of the elements, Na 1s)End the range before the first plasmon, about 10–15 eV above the main peakThe plasmon bump at the high-BE end lifts a Shirley background too high, just as the Ni satellites do.
Wide scans (more than about 40 eV around one peak)The peak ± 10–15 eVLong tails and steps at the ends distort the background.
A peak or Auger line of another element at the window edgeMove that end inside the clean regionAn unrelated peak at the edge sets the background end point. If the line overlaps your peak instead, keep it and add it with Add component.
Spikes or a jump at the first or last pointsCut a few points off that endEdge artefacts set the background level; Remove spikes handles spikes inside the window.

Rule of thumb. After any fit, look at the grey background line. If it rises above the data anywhere, or ends on a peak, satellite or slope, narrow the range or change the background type before you trust any number.

8. Grades, warnings and common problems

The grade beside the spectrum's name sums up the checks: green is fine, amber means read the warning, red means fix the data or settings before trusting the fit.

WarningWhat it meansWhat to do
Signal-to-noise is lowThe peak is not much taller than the noise.Measure more sweeps, or fit with fewer, broader components.
No clear peak / not in this windowThe chosen core level has no peak in the data.Check the core level, the energy column and the charge correction.
Energy axis looks mirroredKinetic energy was read as binding energy, or the reverse.Reopen the file and pick the right energy column in Check how this file was read.
Fit does not describe the dataReduced χ² well above 1.Look at the background first (section 7), then add a missing component or change a shape.
Structured residualThe residual has long runs above or below zero.A component, satellite or the background is wrong where the runs are.
Peak at the edge of the windowA peak is cut off by the fit range.Widen the range or move it to a flat region.
SpikesSingle points far above their neighbours.Click Remove spikes.
Charging (Sample report)C 1s is far from 284.8 eV, or differs between regions.Click Set from C 1s; check for differential charging.
Unexpected elements (survey)The survey shows peaks of elements you did not list.Add them to the element list, or look for contamination.
Beam damage (Pb⁰)Metallic lead appears in a halide perovskite.Compare first and last sweeps; treat Pb⁰ with suspicion.

Before you publish a fit: