Use it when deploying a new ACL or when an ACL seems to have no effect.
Apply IPv4 ACL
Applying an IPv4 ACL attaches it to an interface with ip access-group <name> in|out. Inbound ACLs check packets as they arrive, before routing; outbound ACLs check packets leaving the interface.
1. Draw the flow: which interface does it enter, which does it leave?
2. show ip interface <if> | include access list — ACL on the right interface and direction?
3. show access-lists <name> — counters increase when traffic flows?
4. No counters → wrong interface or direction.
5. Remote change → reload in 10 first, reload cancel after it works.
ACL applied on the right interface and direction → packet compared top-down → first matching entry decides → no match = implicit deny → counter increments on the matching entry
Trace the packet path and inspect other policy attachment points.
Continue only after interpreting the current observation.Context & applicabilityCommon mistakes · platform/version boundaries
Operational reference
Fast context before you go deeper.
ip access-group <acl> inPrimary Commands
Configuration and operational commands for this Topic.
ip access-group <acl> inReferenceApply an IPv4 ACL to inbound traffic on an interface.
Use when: Apply an IPv4 ACL to packets entering the interface.
Quick note: Check interface config plus ACL counter delta for an inbound test.
Cisco IOS / IOS XE · mixedip access-group <acl> outReferenceApply an IPv4 ACL to outbound traffic on an interface.
Use when: Apply an IPv4 ACL to packets leaving the interface.
Quick note: Verify the test is actually forwarded out this interface and counters move.
Cisco IOS / IOS XE · mixedVerification & Troubleshooting
Start with the observed symptom, prove the nearest boundary, and move outward only when the current state is understood.
Use the operational verification above to establish the expected state.
Capture the concrete output, symptom, packet, log or counter before changing anything.
Step 1 Verification and output interpretation Verify boundary
Verify the interface/feature attachment explicitly and correlate ACE counters with traffic traversing that exact direction. Use routing/CEF knowledge to confirm the packet should cross the interface. If counters do not move, verify the path, tuple and ACL name before assuming the rule is wrong. If counters move on a deny, that is strong local evidence of the enforcement boundary; if permits move but service fails, continue beyond the ACL.
Evidence · 1 on this Topic
Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.
Direction is seen from the router: "in" is traffic entering that interface. An outbound ACL does not filter traffic the router itself generates. Applying an ACL that does not exist yet permits everything on IOS; applying one with a mistake can lock you out — use reload in <min> when editing remotely.
show access-lists <name>— entries in order with match counters.show ip interface <if> | include access list— ACLs applied inbound and outbound.show running-config | section access-list— the ACL as configured.show ipv6 access-list <name>— IPv6 ACL entries and counters.clear access-list counters <name>— reset counters before a test.
ReferenceWhat it is1 section · depth on demand
What it is
ip access-group <acl> in|out attaches an IPv4 ACL to a Layer-3 interface in a specific direction. An ACL that is correctly defined but not attached to the packet path cannot filter that flow at the interface boundary.
ReferenceImportant terms & boundaries4 sections · depth on demand
In depth
Applying an ACL: where and in which direction
The Catalyst 9300 IPv4 ACL guide describes three ways to apply ACLs:
| Type | Applied with | Filters |
|---|---|---|
| Router ACL (RACL) | ip access-group <acl> in\|out on an SVI, routed port or Layer 3 EtherChannel | Routed traffic |
| Port ACL (PACL) | ip access-group <acl> in on a Layer 2 interface | Traffic entering the port |
| VLAN map | vlan filter <map> vlan-list <list> | Bridged traffic within a VLAN (one map per VLAN) |
It also gives the order of evaluation: for ingress, port ACL, then VLAN map, then router ACL; for egress, router ACL, then VLAN map, then port ACL.
C9300(config)# interface Vlan20
C9300(config-if)# ip access-group USERS-IN in
C9300(config)# interface Gi1/0/30
C9300(config-if)# ip access-group KIOSK-PACL in
C9300# show ip interface Vlan20 | include access list
Outgoing access list is not set
Inbound access list is USERS-IN
C9300# show platform software fed switch active acl counters hardware
Choosing in or out
| Direction on an SVI | Filters |
|---|---|
in | Traffic from hosts in VLAN 20 towards the router (and onwards) |
out | Traffic routed into VLAN 20 towards its hosts |
A common rule is to filter in as close to the source as possible, so unwanted traffic is dropped early.
Documented points to remember
| Point | Detail |
|---|---|
| Undefined ACL applied to an interface | Permits all traffic |
| Management port | ACLs can't be applied to it |
show ip access-lists counters | Don't include hardware-switched packets; use the platform hardware counters |
log keyword | Sent to the CPU; may be dropped under load |
Safe application
Build and review the ACL first, apply it in a change window, and keep a console or out-of-band session open. An ACL applied in on the SVI you're connected through can cut your own session.
Documented example, not captured output.
Quick reference
An ACL only filters traffic once applied: with ip access-group <name> in|out on an interface, or access-class on VTY lines. One ACL per interface, direction and protocol is allowed.
interface Vlan20
ip access-group USERS-IN in
show ip interface Vlan20 | include access list
Documented example, not captured output.
| Direction | Filters |
|---|---|
| in | Packets entering the interface, before routing |
| out | Packets leaving the interface, after routing |
Router-originated traffic (e.g. pings from the router itself) is not filtered by outbound ACLs.
State model and technical mechanics
An interface ACL evaluates packets in the configured direction relative to the interface. Inbound filtering occurs as packets enter the device before the normal outbound forwarding path; outbound filtering applies to packets selected to leave the interface. The exact feature pipeline can vary, but operationally the key is to know which interface/direction the target packet actually crosses and what source/destination values it has at that point. One ACL definition may be attached in multiple places with different traffic populations. An ACL is an ordered packet-classification policy.
Limits and common misconceptions
An ACL present in running configuration is not an active control until attached to the relevant feature. Likewise, an attached ACL can be operationally irrelevant to a flow that takes another interface/VRF/path. Inbound/outbound labels are device-interface directions, not client/server semantics. Keep the enforcement point explicit whenever an ACL is used as evidence.
ReferenceConfiguration & state1 section · depth on demand
Design and configuration model
Choose attachment from the topology and packet path, not only from ACL type. Confirm whether NAT, PBR, VRF or other features alter the tuple/path relevant to the policy. Document interface, direction and purpose next to the ACL. Avoid changing an ACL definition that is reused elsewhere without checking all attachments, because one edit can change multiple enforcement points. Design ACLs from explicit traffic intent.
Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Verification history & basis
When and against what this Topic was checked. Later text edits do not count as a new check.
Authoritative/upstream documentation reviewed for bounded claims in Security → ACL → Apply IPv4 ACL. Documentation verification only; this is not observed lab or production Evidence.
Basis: https://www.rfc-editor.org/rfc/rfc791.html · confidence 94%Quick lookup tables
Interface ACL direction
Map direction from the router/interface perspective
| Direction | Packet position | Fast check |
|---|---|---|
in | Arriving on the interface | Did the packet enter the router here? |
out | Leaving through the interface | Will the router forward the packet out here? |
Apply IPv4 ACL · technical reference
Compact network access/security mechanics, policy and evidence boundaries for fast lookup.
| Item | Question |
|---|---|
| Interface | Does the flow actually traverse it? |
| Direction | Inbound or outbound relative to device? |
| Tuple | What addresses/ports exist here? |
| Counter | Does the intended ACE match traffic? |
Deep reference
Additional depth
Inbound vs outbound
Inbound means the packet is evaluated as it enters that interface. Outbound means it is evaluated as it is about to leave that interface. Always describe direction from the device/interface perspective. For a client-to-server flow, the same packet can be inbound on one interface and outbound on another.