SVG elements can be modified using attributes that specify details about exactly how the element should be handled or rendered. Below is a list of all of the attributes available in SVG along with links to reference documentation to help you learn which elements support them and how they work.
SVG attributes A to Z
A
accent-heightaccumulateadditivealignment-baselineallowReorderalphabeticamplitudearabic-formascentattributeNameattributeTypeautoReverseazimuth
B
C
calcModecap-heightclassclipclipPathUnitsclip-pathclip-rulecolorcolor-interpolationcolor-interpolation-filterscolor-profilecolor-renderingcontentScriptTypecontentStyleTypecursorcxcy
D
E
F
fillfill-opacityfill-rulefilterfilterResfilterUnitsflood-colorflood-opacityfont-familyfont-sizefont-size-adjustfont-stretchfont-stylefont-variantfont-weightformatfromfrfxfy
G
g1g2glyph-nameglyph-orientation-horizontalglyph-orientation-verticalglyphRefgradientTransformgradientUnits
H
I
K
L
M
marker-endmarker-midmarker-startmarkerHeightmarkerUnitsmarkerWidthmaskmaskContentUnitsmaskUnitsmathematicalmaxmediamethodminmode
N
O
offsetopacityoperatororderorientorientationoriginoverflowoverline-positionoverline-thickness
P
panose-1paint-orderpathpathLengthpatternContentUnitspatternTransformpatternUnitspingpointer-eventspointspointsAtXpointsAtYpointsAtZpreserveAlphapreserveAspectRatioprimitiveUnits
R
rradiusreferrerPolicyrefXrefYrelrendering-intentrepeatCountrepeatDurrequiredExtensionsrequiredFeaturesrestartresultrotaterxry
S
scaleseedshape-renderingslopespacingspecularConstantspecularExponentspeedspreadMethodstartOffsetstdDeviationstemhstemvstitchTilesstop-colorstop-opacitystrikethrough-positionstrikethrough-thicknessstringstrokestroke-dasharraystroke-dashoffsetstroke-linecapstroke-linejoinstroke-miterlimitstroke-opacitystroke-widthstylesurfaceScalesystemLanguage
T
tabindextableValuestargettargetXtargetYtext-anchortext-decorationtext-renderingtextLengthtotransformtransform-origintype
U
V
v-alphabeticv-hangingv-ideographicv-mathematicalvaluesvector-effectversionvert-adv-yvert-origin-xvert-origin-yviewBoxviewTargetvisibility
W
X
xx-heightx1x2xChannelSelectorxlink:actuatexlink:arcrolexlink:hrefxlink:rolexlink:showxlink:titlexlink:typexml:basexml:langxml:space
Y
Z
SVG attributes by category
Generic Attributes
Core attributes
id, lang, tabindex, xml:base, xml:lang, xml:space
Style Attributes
Conditional Processing Attributes
externalResourcesRequired, requiredExtensions, requiredFeatures, systemLanguage.
XLink Attributes
xlink:href, xlink:type, xlink:role, xlink:arcrole, xlink:title, xlink:show, xlink:actuate
Presentation Attributes
alignment-baseline, baseline-shift, clip, clip-path, clip-rule, color, color-interpolation, color-interpolation-filters, color-profile, color-rendering, cursor, direction, display, dominant-baseline, enable-background, fill, fill-opacity, fill-rule, filter, flood-color, flood-opacity, font-family, font-size, font-size-adjust, font-stretch, font-style, font-variant, font-weight, glyph-orientation-horizontal, glyph-orientation-vertical, image-rendering, kerning, letter-spacing, lighting-color, marker-end, marker-mid, marker-start, mask, opacity, overflow, pointer-events, shape-rendering, stop-color, stop-opacity, stroke, stroke-dasharray, stroke-dashoffset, stroke-linecap, stroke-linejoin, stroke-miterlimit, stroke-opacity, stroke-width, text-anchor, text-decoration, text-rendering, transform, transform-origin, unicode-bidi, vector-effect, visibility, word-spacing, writing-mode
Filters Attributes
Filter Primitive Attributes
Transfer Function Attributes
type, tableValues, slope, intercept, amplitude, exponent, offset
Animation Attributes
Animation Attribute Target Attributes
Animation Timing Attributes
begin, dur, end, min, max, restart, repeatCount, repeatDur, fill
Animation Value Attributes
calcMode, values, keyTimes, keySplines, from, to, by, autoReverse, accelerate, decelerate
Animation Addition Attributes
Event Attributes
Animation Event Attributes
onbegin, onend, onrepeat
Document Event Attributes
onabort, onerror, onresize, onscroll, onunload
Global Event Attributes
oncancel, oncanplay, oncanplaythrough, onchange, onclick, onclose, oncuechange, ondblclick, ondrag, ondragend, ondragenter, ondragexit, ondragleave, ondragover, ondragstart, ondrop, ondurationchange, onemptied, onended, onerror, onfocus, oninput, oninvalid, onkeydown, onkeypress, onkeyup, onload, onloadeddata, onloadedmetadata, onloadstart, onmousedown, onmouseenter, onmouseleave, onmousemove, onmouseout, onmouseover, onmouseup, onmousewheel, onpause, onplay, onplaying, onprogress, onratechange, onreset, onresize, onscroll, onseeked, onseeking, onselect, onshow, onstalled, onsubmit, onsuspend, ontimeupdate, ontoggle, onvolumechange, onwaiting
Graphical Event Attributes
onactivate, onfocusin, onfocusout
