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.
- 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. - 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.
- 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.
- 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. | Part | What it does |
|---|---|---|
| 1 | Top bar | Open files (VAMAS .vms, CSV or text), Load demo data to practise, Export all results (CSV), Clear, Quit. |
| 2 | Sidebar | Your samples and their spectra. Drag files onto the dashed box to open them. The coloured dot shows the quality grade of each spectrum. |
| 3 | Tabs | Fit, Sample report, Auto fit fixed, Batch, References, Library, Help (section 4). |
| 4 | Fit range | First and last binding energy used for the fit. Change them and click Apply; Full range goes back to the whole spectrum (section 6). |
| 5 | Elements in this sample | Type the elements present (e.g. Ni, Se, C, O, N) so the auto-fit only considers overlaps from these. |
| 6 | Fit with | Tick what the fit may use: core levels, satellites, Auger lines. |
| 7 | Fit controls | Core 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). |
| 8 | Graph | Data (circles), background (grey), components (coloured), envelope (black) and the residual underneath. |
| 9 | Components table | Below the graph: one row per component (section 5). |
| 10 | Data quality and notes | Below the table: green/amber/red checks and notes on ambiguous assignments (section 8). |
| 11 | Bottom bar | Version number and how to acknowledge XPSfit. |
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.
- 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).
- Check the columns in that window before clicking OK. A wrong column is the most common reason for a fit that makes no sense.
- 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.
- 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.
- Auto-fit. XPSfit tries the chemical states in its library and keeps only components that the data clearly support.
- 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.
- 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.
| Tab | Use it to |
|---|---|
| Fit | Fit one spectrum: fit range, elements, auto-fit, the graph, the components table, quality checks and notes. |
| Sample report | Charge 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 fixed | Choose 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. |
| Batch | Fit many spectra at once, automatically or with a saved template, so every sample gets the same model and comparisons are fair. |
| References | Save 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. |
| Library | Look 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 %. |
| Help | A 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:
| Column | Meaning |
|---|---|
| Component | Chemical 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. |
| Area | Fitted 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. |
| Shape | Line 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. |
| ✕ Delete | Removes 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:
- Click a peak to select it; its row in the table is highlighted.
- Round handle at the top: drag to move the peak and change its height.
- Square handles at half height: drag sideways to change the width (FWHM).
- Drag the peak itself to move it without changing its shape.
- Prev / Next (under Auto-fit) step back and forward through your fits, so any change can be undone.
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.
How to fit 2p₃/₂ on its own:
- Open the spectrum and look at it on the Fit tab.
- In Fit range (BE), set the low end on the flat part 5–7 eV below the main peak (846 eV for Ni).
- Set the high end at the lowest point of the valley between the 2p₃/₂ satellites and the 2p₁/₂ peak (866.5 eV here).
- Click Apply, then Auto-fit. The graph now shows only that range, and the background ends at your two energies.
- 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).
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.
| Component | BE (eV) | FWHM (eV) | Share of Ni 2p₃/₂ area |
|---|---|---|---|
| Ni–Se (NiSe) | 852.85 | 1.1 | 39 % |
| Ni²⁺ (Ni–O / Ni–OH, surface oxidation) | 855.6 | 2.7 | 42 % |
| Satellite | 858.5 | about 3.9 | 10 % |
| Satellite | 861.4 | 2.7 | 8 % |
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
- Each spectrum keeps its own range. Changing the range clears the current fit, because the old fit no longer matches the data points.
- Full range returns to the whole spectrum, and Prev/Next bring back the range each fit was made with.
- Report the fit range with the background type when you publish.
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.
| Spectrum | What to fit | Why |
|---|---|---|
| Ni 2p | 2p₃/₂ with its satellites, about 846–866.5 eV; 2p₁/₂ separately | Strong satellites; the scan's high-BE end lies inside the 2p₁/₂ satellites (section 6). |
| Co 2p | 2p₃/₂ with its satellites, about 775–794 eV | Same as Ni: Co²⁺ satellites fill the region up to 2p₁/₂. |
| Cu 2p | 2p₃/₂ with the Cu²⁺ shake-up, about 928–948 eV | The shake-up satellites at 940–945 eV belong in the fit; 2p₁/₂ (about 952 eV) can be left out. |
| Mn 2p | 2p₃/₂, about 636–650 eV | Multiplet splitting broadens each line; the 2p₁/₂ region adds little. |
| Fe 2p | Usually the whole 2p region, not split | 2p₁/₂ (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 3d | One line, e.g. Zn 2p₃/₂ about 1015–1030 eV | Very 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 earths | The whole 3d region, not split | Satellites 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 peak | The 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 eV | Long tails and steps at the ends distort the background. |
| A peak or Auger line of another element at the window edge | Move that end inside the clean region | An 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 points | Cut a few points off that end | Edge 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.
| Warning | What it means | What to do |
|---|---|---|
| Signal-to-noise is low | The peak is not much taller than the noise. | Measure more sweeps, or fit with fewer, broader components. |
| No clear peak / not in this window | The chosen core level has no peak in the data. | Check the core level, the energy column and the charge correction. |
| Energy axis looks mirrored | Kinetic 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 data | Reduced χ² well above 1. | Look at the background first (section 7), then add a missing component or change a shape. |
| Structured residual | The 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 window | A peak is cut off by the fit range. | Widen the range or move it to a flat region. |
| Spikes | Single 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:
- Use raw counts (CPS) from the instrument, not data normalised to 0–1. XPSfit then estimates the noise and uncertainties properly.
- Charge-correct with C 1s and state the reference energy.
- Report the fit range, background type, line shapes and constraints.
- For transition-metal 2p, compare with reference spectra of standards (References tab).
- Read every note about ambiguous assignments; XPSfit tells you when two chemical states fit equally well.